Description Usage Arguments Details Value Author(s) Examples
plot_extremes
Plot floods and droughts episodes using the function
find_flood_drought
. This function employs the
definition proposed by Mckee et al. (1993) using a time series of standardized
precipitation values. A drought (flood) is defined as a period of time in
which the SPI is continuously negative (positive) reaching at least
one value lower (higher) or equal to -1 (1).
1 | plot_extremes(data, threshold = 1)
|
data |
A |
threshold |
An numeric value used to detect the extreme events, 1 (-1) is used by default as proposed by Mckee et al. (1993). |
Although the definition of Mckee et al. (1993) uses a threshold of 1 (-1). Other values can be used for this threshold.
A ggplot
object. The graph is shown when this object is printed.
Erick A. Chacon-Montalvan
1 2 3 4 5 6 7 | data(simrain)
spi_rain <- mbsi(simrain$rain, simrain$time)
# Visualize extreme events
plot_extremes(spi_rain, threshold = 2)
plot_extremes(spi_rain, threshold = 1.5)
plot_extremes(spi_rain, threshold = 1)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.