Learn R Programming

pgam (version 0.3.3)

plot.pgam: Plot of estimated curves

Description

Plot of the local level and, when semiparametric model is fitted, the estimated smooth terms.

Usage

## S3 method for class 'pgam':
plot(x, rug = TRUE, se = TRUE, at.once = FALSE, ...)

Arguments

x
object of class pgam holding the fitted model
rug
if TRUE a density rug is drawn on the bottom of the graphic
se
if TRUE error band is drawn around the fitted values
at.once
if TRUE each plot goes to a separate window, else the user is prompted to continue
...
further arguments passed to method

Value

  • No value returned.

Details

Error band of smooth terms is approximated.

See Also

pgam, pgam.fit, pgam.likelihood

Examples

Run this code
library(pgam)
data(aihrio)
attach(aihrio)
form <- ITRESP5~f(WEEK)+HOLIDAYS+rain+PM+g(tmpmax,7)+g(wet,3)
m <- pgam(form,aihrio,omega=.8,beta=.01,maxit=1e2,eps=1e-4,optim.method="BFGS",partial.resid="response")

plot(m,at.once=TRUE)

Run the code above in your browser using DataLab