compperiods: Compare residual variability across time periods

Description Usage Arguments Value See Also Examples

Description

The function finds the seasonal signal in the first of two time periods within the data series. This signal is used to calculate residual flows in the first time period and "historical residuals", the residuals when the second period is compared to the signal in the first period.

The output of the function gives event information for all residual events greater than σ as calculated from the functions sigmaHighFlows and sigmaLowFlows.

Usage

1
2
3
compare.periods(p1, p2, x, plot=T)
## S3 method for class 'compflows'
 plot(x, ...)

Arguments

p1

Character vector specifying start and end date of the first period. "YYYY-MM-DD" format.

p2

Character vector specifying start and end date of the second period. "YYYY-MM-DD" format.

x

Matrix with first column specifying dates and second column specifying raw discharge data.

plot

Logical; defaults to TRUE. If TRUE, the seasonal signal for both periods will be plotted.

...

Other parameters.

Value

Object of S3 ckass compflows with the following items:

sigma.low

Estimate of σ-lf from period 1

sigma.high

Estimate of σ-hf from period 1

p1.levents

Matrix of low flow events for period 1

p1.hevents

Matrix of high flow events for period 1

p2.levents

Matrix of low flow events for period 2

p2.hevents

Matrix of high flow events for period 2

See Also

sigmaHighFlows sigmaLowFlows

Examples

1
2
3
4
5
6
# load data
data("sycamore")

# compare for periods from 1960 to 1979 and 1980 to 1999
compare.periods(c("1960-01-01", "1979-12-31"), 
c("1980-01-01", "1999-12-31"), sycamore)

discharge documentation built on May 2, 2019, 5:54 a.m.