bGAMM | R Documentation |
Fit a semiparametric mixed model or a generalized semiparametric mixed model.
bGAMM(fix=formula, add=formula, rnd=formula,
data, lambda, family = NULL, control = list())
fix |
a two-sided linear formula object describing the
fixed-effects part of the model, with the response on the left of a
|
add |
a one-sided linear formula object describing the
additive part of the model, with the additive terms on the right side of a
|
rnd |
a two-sided linear formula object describing the
random-effects part of the model, with the grouping factor on the left of a
|
data |
the data frame containing the variables named in
|
lambda |
the smoothing parameter that controls the smoothness of the additive terms. The optimal smoothing parameter is a tuning parameter of the procedure that has to be determined, e.g. by use of information criteria or cross validation. |
family |
a GLM family, see |
control |
a list of control values for the estimation algorithm to replace the default values returned by the function |
Generic functions such as print
, predict
, summary
and plot
have methods to show the results of the fit.
The predict
function uses also estimates of random effects for prediction, if possible (i.e. for known subjects of the grouping factor).
The plot
function shows the estimated smooth functions. Single functions can be specified by a suitable vector in the which
argument.
Default is which=Null
and all smooth functions (up to a maximum of nine) are shown.
call |
a list containing an image of the |
coefficients |
a vector containing the estimated fixed effects |
ranef |
a vector containing the estimated random effects. |
spline.weights |
a vector containing the estimated spline coefficients. |
StdDev |
a scalar or matrix containing the estimates of the random effects standard deviation or variance-covariance parameters, respectively. |
fitted.values |
a vector of fitted values. |
phi |
estimated scale parameter, if |
HatMatrix |
hat matrix corresponding to the final fit. |
IC |
a matrix containing the evaluated information criterion for the different covariates (columns) and for each boosting iteration (rows). |
IC_sel |
a vector containing the evaluated information criterion for the selected covariate at different boosting iterations. |
components |
a vector containing the selected components at different boosting iterations. |
opt |
number of optimal boosting steps with respect to AIC or BIC, respectively, if |
Deltamatrix |
a matrix containing the estimates of fixed and random effects (columns) for each boosting iteration (rows). |
Q_long |
a list containing the estimates of the random effects standard deviation or variance-covariance parameters, respectively, for each boosting iteration. |
fixerror |
a vector with standrad errors for the fixed effects. |
ranerror |
a vector with standrad errors for the random effects. |
smootherror |
a matrix with pointwise standard errors for the smooth function estimates. |
Andreas Groll andreas.groll@stat.uni-muenchen.de
Groll, A. and G. Tutz (2012). Regularization for Generalized Additive Mixed Models by Likelihood-Based Boosting. Methods of Information in Medicine 51(2), 168–177.
bGAMMControl
data("soccer")
gamm1 <- bGAMM(points ~ ball.possession + tackles,
~ transfer.spendings + transfer.receits
+ unfair.score + ave.attend + sold.out,
rnd = list(team=~1), data = soccer, lambda = 1e+5,
family = poisson(link = log), control = list(steps=200, overdispersion=TRUE,
start=c(1,rep(0,25))))
plot(gamm1)
# see also demo("bGAMM-soccer")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.