Learn R Programming

wq (version 0.4.6)

seaRoll: Rolling Seasonal Kendall trend test

Description

Calculates the Seasonal Kendall test of significance, including an estimate of the Sen slope, for rolling windows over a time series.

Usage

seaRoll(x, w = 10, plot = FALSE, pval = .05, mval = .5, 
         pchs = c(19, 21), xlab = NULL, ylab = NULL, ...)

Arguments

Value

seaRoll returns a matrix with one row per time window containing the Sen slope, the relative Sen slope, and the p-value. Rows are labelled with the leading year of the window.

Rdversion

1.1

Details

The function seaRoll applies seaKen to rolling time windows of width w. A minimum w of five years is required. For any window, a season is considered missing if half or more of the possible comparisons between the first and last 20% of the years is missing. If mval or more of the seasons are missing, then that windowed trend is considered to be missing.

If plot = TRUE, a point plot will be drawn with the Sen slope plotted at the leading year of the trend window. The plot symbols indicate, respectively, that the trend is significant or not significant. The plot can be customized by passing any arguments used by plot.default, as well as graphical parameters described in par.

See Also

seaKen

Examples

Run this code
chl27 <- sfbayChla[, 's27']
seaRoll(chl27)
seaRoll(chl27, plot = TRUE)

Run the code above in your browser using DataLab