deleteZeroComponents: Delete random effect terms with zero variance
Description
Is used in the cAIC function if method = "steinian" and
family = "gaussian". The function deletes all random effects terms
from the call if corresponding variance parameter is estimated to zero and
updates the model in merMod.
Usage
deleteZeroComponents(m)
# S3 method for lme
deleteZeroComponents(m)
# S3 method for merMod
deleteZeroComponents(m)
Arguments
m
An object of class merMod fitted by
lmer of the lme4-package or of class
lme.
Value
An updated object of class merMod
or of class lme.
NULL
NULL
WARNINGS
For models called via gamm4 or gamm
no automated update is available.
Instead a warning with terms to omit from the model is returned.
Details
For merMod class models:
Uses the cnms slot of m and the relative covariance factors to
rewrite the random effects part of the formula, reduced by those parameters
that have an optimum on the boundary. This is necessary to obtain the true
conditional corrected Akaike information. For the theoretical justification
see Greven and Kneib (2010). The reduced model formula is then updated. The
function deleteZeroComponents is then called iteratively to check if in the
updated model there are relative covariance factors parameters on the
boundary.