print.rgam: Print a rgam object

Description Usage Arguments Details Value See Also Examples

View source: R/print.rgam.R

Description

Print a summary of the rgam path at each step along the path.

Usage

1
2
## S3 method for class 'rgam'
print(x, digits = max(3, getOption("digits") - 3), ...)

Arguments

x

Fitted rgam object.

digits

Significant digits in printout.

...

Additional print arguments.

Details

The call that produced the object x is printed, followed by a five-column matrix with columns NonZero, Lin, NonLin, columns say how many nonzero, linear and nonlinear terms there are. the percent deviance explained (relative to the null deviance).

Value

The matrix above is silently returned.

See Also

rgam.

Examples

1
2
3
4
5
6
7
set.seed(1)
n <- 100; p <- 12
x <- matrix(rnorm(n * p), n, p)
beta <- matrix(c(rep(2, 3), rep(0, 9)), ncol = 1)
y <- x %*% beta + x[, 4]^2 + rnorm(n)
fit <- rgam(x, y)
print(fit)

relgam documentation built on Jan. 13, 2020, 5:06 p.m.