Fit rating curve using loess smoother
Usage
rc_loess(
discharge,
stage,
...,
data = NULL,
degree = 2,
span = 0.75,
extrapolate = TRUE,
variance = var_none()
)Arguments
- discharge
<
data-masking> Discharge: a vector, or an expression evaluated indata, such as a column name.- stage
<
data-masking> Stage: a vector, or an expression evaluated indata, such as a column name.- ...
Must be empty. Present so that every argument after it has to be named in full.
- data
Optional data frame in which
dischargeandstageare evaluated.- degree
Degree of local polynomials (1 or 2).
- span
Smoothing parameter, passed to
stats::loess().- extrapolate
Single logical; allow extrapolation beyond the observed stage range? Default is
TRUE. IfFALSE, predictions outside the range of the gaugings areNA. (This sets loess'ssurfaceto"direct"or"interpolate"; seestats::predict.loess().)- variance
How the variance of the gaugings about the curve is modelled:
var_none()(or"none", the default),var_prop()(or"prop"), orvar_spec()with the variances. See variance. Undervar_prop()the loess curve is refitted in rounds, like the parametric fits.
Value
An rc_loess object; see rating_curve for its contents. A loess
curve has no parameters, so curve_parameters is an empty list.