plot.loadReg: Diagnostic Plot

Description Usage Arguments Details Value Note See Also Examples

View source: R/plot.loadReg.R

Description

Plot rating-curve load model diagnostics.

Usage

1
2
## S3 method for class 'loadReg'
plot(x, which = "All", set.up = TRUE, span = 1, ...)

Arguments

x

an object of class "loadReg"—output from loadReg

which

either "All" or any of a sequence from 1 to 7 indicating which plot, see Details.

set.up

set up the graphics page?

span

the span to use for the loess smooth. Set to 0 to suppress.

...

further arguments passed to or from other methods.

Details

Seven graphs can be produced by this function. If which is "All," then all plots are produced. The argument which can also be the name of an explanatory variable so that a partial residual plot is created for a single variable. Or which can be any of a sequence of numbers from 1 thorugh 7. Numeric values for which:

  1. Observed vs. fitted.

  2. Fitted vs. Residual

  3. S-L plot

  4. A correlogram if dates are available in the model or in the data set

  5. Q-normal

  6. Tukey boxplots for oberved and estimated

  7. Partial residual plots for each explanatory variable

Value

The object x is returned invisibly.

Note

This plotting function uses the core routines in the smwrGraphs package. It requires a graphics page that is set up from the functions in that package (setpage or setPDF) if set.up is FALSE. The graphs that are produced by this function are based on the publication guidelines of the USGS.

See Also

censReg, setPage, setPDF

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
# From application 1 in the vignettes
## Not run: 
data(app1.calib)
app1.lr <- loadReg(Phosphorus ~ model(1), data = app1.calib, 
 flow = "FLOW", dates = "DATES", conc.units="mg/L",
 station="Illinois River at Marseilles, Ill.")
# Produce the full suite of diagnostic plots
plot(app1.lr)

## End(Not run)

USGS-R/rloadest documentation built on Oct. 2, 2020, 5:21 a.m.