Learn R Programming

WH (version 1.1.2)

plot.WH_1d: Plot Method for a Whittaker-Henderson Fit

Description

Plot Method for a Whittaker-Henderson Fit

Usage

# S3 method for WH_1d
plot(x, what = "fit", trans, ...)

Value

A plot representing the desired element from the fit

Arguments

x

An object of class "WH_1d" returned by the WH_1d() function

what

What should be plotted. Should be one of fit (the model fit and standard deviation, the default), res for residuals and edf for the effective degrees of freedom.

trans

An (optional) transformation to be applied to the data. By default the identity function

...

Not used

Examples

Run this code
d <- portfolio_mort$d
ec <- portfolio_mort$ec

fit <- WH_1d(d, ec)
plot(fit)
plot(fit, "res")
plot(fit, "edf")

Run the code above in your browser using DataLab