View source: R/hysteresis_plot.R
hysteresis_plot | R Documentation |
This function plots a water discharge (Q
) and suspended
sediment concentration (SSC
) relationship.
hysteresis_plot( dataframe, datetime, q, ssc, base_font_size = 12, legend = "bottom", ... )
dataframe |
A data set object |
datetime |
Datetime variable (column in POSIXct format), optional |
q |
Water discharge variable (or water stage) |
ssc |
Suspended sediment concentration variable |
base_font_size |
Font size (numeric, 12 by default) |
legend |
the position of legends ("none", "left", "right", "bottom", "top", or two-element numeric vector) |
... |
Other arguments passed to |
A ggplot2
object
library(dplyr) library(ggplot2) data(djan) output_table <- hydro_events( dataframe = djan, q = discharge, datetime = time, window = 21 ) output_table %>% filter(he == 2) %>% hysteresis_plot(q = discharge, ssc = SS)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.