Learn R Programming

FlowScreen (version 2.0)

drop.years: Drop hydrologic years

Description

Removesthose hydrologic years where the fraction of missing data is above the defined threshold.

Usage

drop.years(TS, NAthresh = 0.8)

Value

Returns TS data.frame with hydrologic years with

above the user-defined threshold dropped.

Arguments

TS

data.frame of streamflow time series loaded with read.flows.

NAthresh

Numeric value indicating the threshold for missing data points in any one year. Default is 0.80, indicating that years with more than 80 percent missing data will be omitted from the metric calculations. This value should always be set to greater than 0.1, as years with fewer observations than approximately 1 month will cause errors.

Author

Jennifer Dierauer

Examples

Run this code
data(caniapiscau)
cania.ts <- create.ts(caniapiscau, hyrstart = 4)
cania.ts <- drop.years(cania.ts, NAthresh = 0.75)

Run the code above in your browser using DataLab