Functions to be used as plugins to prcurve
that fit
smooth functions to each variable that, when combined, give the
principal curve. The functions act as wrappers to the main fitting
functions, which currently include smooth.spline
and
gam
.
smoothSpline(lambda, x, choose = TRUE, complexity, ...,
penalty = 1, cv = FALSE, keep.data = FALSE,
control.spar = list(low = 0))smoothGAM(lambda, x, choose = TRUE, complexity, bs = "tp", ...,
family = gaussian(), method = "REML", select = FALSE,
control = gam.control())
An object of class "prcurveSmoother"
with the following
components:
for each observations, its arc-length from the beginning of the curve.
numeric vector of response values.
numeric vector of fitted values for the observations generated from the fitted smooth function.
numeric; the degrees of freedom used for the smooth
function. The exact details of what these pertain to are in the help
for the respective fitting functions smooth.spline
and
gam
.
the object fitted by the wrapped fitting function.
the current projection function; the position that each sample projects to on the current principal curve. This is the predictor variable or covariate in the smooth function.
numeric vector; used as the response variable in the smooth
function. The principal curve algorithm fits a separate scatterplot
smoother (or similar smoother) to each variable in X
in turn as the response.
logical; should the underlying smoother function be allowed to choose the degree of smooth complexity for each variable?
numeric; the complexity of the fitted smooth functions.
arguments to
smooth.spline
.
arguments to s
.
arguments to gam
.
arguments passed on the the underlying function
smooth.spline
and users should read that function's
help page for further details.
Gavin L. Simpson
prcurve
for how these functions are used.