anlz_domopep: Analyze monthly DO values relative to threshold

View source: R/anlz_domopep.R

anlz_domopepR Documentation

Analyze monthly DO values relative to threshold

Description

Analyze monthly DO values relative to threshold

Usage

anlz_domopep(dodat, thr = 3, impute = TRUE)

Arguments

dodat

result returned from read_pepdo

thr

numeric indicating appropriate dissolved oxygen thresholds, usually 3 mg/L for acute, 4.8 mg/L for chronic

impute

logical indicating of missing dissolved oxygen values are imputed with the year, month, site average

Details

The dodat data object can be used as input without downloading USGS data

The date are summarized as three different values, where do_mgl is the average of all daily DO averages across the month, below_ave is the proportion of days in a month when concentrations in a given day fell below the threshold (1 would mean all days had an instance of DO below the threshold, 0 would mean none), and below_maxrun is the maximum number of sequential days in a month when concentrations in a given day fell below the threshold (30 or 31, depending on month, would indicate all days in a month had an instance of DO below the threshold).

If impute = TRUE, missing dissolved oxygen values in the complete daily time series are imputed to the average for the year, month, site combination. This is often necessary to create summary values that make sense. For example, if a month has incomplete data, the below_ave summary may indicate a value of one if all daily averages in the available data are below the threshold, whereas the below_maxrun summary may indicate a maximum run of days not equal to the number of days in the month.

Value

data.frame

Examples

data(dodat)
dat <- anlz_domopep(dodat)
dat

tbep-tech/peptools documentation built on March 13, 2024, 4:22 p.m.