knitr::opts_chunk$set( collapse = TRUE, comment = "#>", fig.path = "man/figures/README-", out.width = "100%" )
The loadflux package is build for the comprehensive analysis of the intra-event suspended sediment dynamics.
You can install the development version from GitHub with:
# install.packages("devtools") devtools::install_github("atsyplenkov/loadflux")
This is a basic example which shows you how to split your series into hydrological events:
library(dplyr) library(loadflux) data(djan) df <- djan %>% hydro_events(q = discharge, datetime = time, window = 21) head(df)
Then you can plot the hysteresis loop by running hysteresis_plot
library(ggplot2) df %>% filter(he == 2) %>% hysteresis_plot(q = discharge, ssc = SS, base_font_size = 14)
This package also contains several function for hysteresis index calculation:
Added
SHI - Simple Hystersis Index from Tsyplenkov et al., 2020AHI - Aich's Hysteresis Index from Aich et al., 2014Pending
HImid - Hysteresis Index from Lawler et al., 2006To calculate a hysteresis index for your event run as follows:
df %>% filter(he == 2) %>% SHI(q = discharge, ssc = SS)
This package was developed in accordance to the Development program of the Interdisciplinary Scientific and Educational School of M.V. Lomonosov Moscow State University "Future Planet and Global Environmental Change"
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.