gam.parser {mgcv} | R Documentation |
This is an internal function of package mgcv
. It is a service routine for
gam
which splits of the strictly parametric part of the model formula and returns it as a formula and interprets the smooth parts
of the model formula.
The processing of
the smooth terms results in the return of the basis dimension for each smooth term, whether
or not the smooth term is to be treated as a pure regression spline
(i.e. one without a penalty) and the type of basis used to represent
the spline. It also returns an array of covariate names which are arguments of smooths, and the name of the response variable.
For further information on usuage see code for gam
.
The code does not check for rank defficiency of the model matrix that may result from including the same covariates in the smooth and parametric parts of the model - it will likely just fail instead!
Simon N. Wood snw@st-and.ac.uk
Gu and Wahba (1991) Minimizing GCV/GML scores with multiple smoothing parameters via the Newton method. SIAM J. Sci. Statist. Comput. 12:383-398
Wood (2000) Modelling and Smoothing Parameter Estimation with Multiple Quadratic Penalties. JRSSB 62(2):413-428
http://www.ruwpa.st-and.ac.uk/simon.html