An internal function, called by fosr()
, that fits additive models
with linear constraints via a call to gam
or
bam
in the mgcv package.
amc(y, Xmat, S, gam.method = "REML", C = NULL, lambda = NULL, ...)
A list with the following elements:
the gam
object returned by gam
or bam
.
coefficients with respect to design matrix Xmat
,
derived from the gam()
fit.
outputs used by
fosr
.
the gam.method
argument of the call to
amc
.
response vector.
design matrix.
list of penalty matrices.
smoothing parameter selection method: "REML" for restricted maximum likelihood, "GCV.Cp" for generalized cross-validation.
matrix of linear constraints. Dimension should be number of
constraints times ncol(Xmat)
.
smoothing parameter value. If NULL
, the smoothing
parameter(s) will be estimated.
Philip Reiss phil.reiss@nyumc.org
The additive model is fitted using gam
, unless there
are more than 10000 responses; in that case bam
is
used.
fosr