drywetlong {INQC} | R Documentation |
Detects wet/dry long periods
Description
This function detects episodes of too many consecutive wet or dry days
Usage
drywetlong(x, ret = 300, sueco = 9.9, dry = TRUE, wet = TRUE)
Arguments
x |
vector with values |
ret |
pseudo-return period (pareto-based) to compute the maximum tolerable spell |
sueco |
threshold for dividing dry and wet. This is useful to label other binary sequences, e.g. for 0 radiation. Now it is <= and >, instead of < and >= |
dry |
if set to TRUE, dry sequences are sent to result; if FALSE, omitted |
wet |
same as previous, for wet sequences |
Value
list of positions in the input data time series which do not pass QC test
Examples
#Extract the ECA&D data file from the example data folder
path2inptfl<-system.file("extdata", "RR_SOUID132730.txt", package = "INQC")
#Read the data file
x<-readecad(input=path2inptfl,missing= -9999)[,4:4]
#Find all suspicious positions in the precipitation time series
drywetlong(x,ret=300,sueco=9.9,dry=TRUE,wet=TRUE)
#Introduce the long wet period
x[1:600]<-10
#Find all suspicious positions in the precipitation time series
drywetlong(x,ret=300,sueco=9.9,dry=TRUE,wet=TRUE)
[Package INQC version 2.0.5 Index]