nobs.kspm: Extract the number of observations from a Kernel Semi...

Description Usage Arguments Value Author(s) See Also Examples

View source: R/nobsKspm.R

Description

Extract the number of observations use to estimate the model coefficients. This is principally intented to be used in computing BIC (see extractAIC.kspm).

Usage

1
2
## S3 method for class 'kspm'
nobs(object, ...)

Arguments

object

an object of class "kspm", usually, a result of a call to kspm.

...

additional optional argument (currently unused).

Value

A single number (integer).

Author(s)

Catherine Schramm, Aurelie Labbe, Celia Greenwood

See Also

kspm for fitting model, extractAIC.kspm.

Examples

1
2
3
4
x <- 1:15
y <- 3*x + rnorm(15, 0, 2)
fit <- kspm(y, kernel = ~ Kernel(x, kernel.function = "linear"))
nobs(fit)

KSPM documentation built on Aug. 10, 2020, 5:07 p.m.