glmm | R Documentation |
glmm
is used to fit a single generalized mixed model via Monte Carlo
Expectation Conditional Minimization (MCECM). Unlike glmmPen
, no model selection
is performed.
glmm(
formula,
data = NULL,
family = "binomial",
covar = NULL,
offset = NULL,
optim_options = optimControl(),
adapt_RW_options = adaptControl(),
trace = 0,
tuning_options = lambdaControl(),
progress = TRUE,
...
)
formula |
a two-sided linear formula object describing both the fixed effects and
random effects part of the model, with the response on the left of a ~ operator and the terms,
separated by + operators, on the right. Random-effects terms are distinguished by vertical bars
("|") separating expression for design matrices from the grouping factor. |
data |
an optional data frame containing the variables named in |
family |
a description of the error distribution and link function to be used in the model.
Currently, the |
covar |
character string specifying whether the covariance matrix should be unstructured
("unstructured") or diagonal with no covariances between variables ("independent").
Default is set to |
offset |
This can be used to specify an a priori known component to be included in the
linear predictor during fitting. Default set to |
optim_options |
a structure of class "optimControl" created
from function |
adapt_RW_options |
a list of class "adaptControl" from function |
trace |
an integer specifying print output to include as function runs. Default value is 0. See Details for more information about output provided when trace = 0, 1, or 2. |
tuning_options |
a list of class "selectControl" or "lambdaControl" resulting from
|
progress |
a logical value indicating if additional output should be given showing the
progress of the fit procedure. If |
... |
additional arguments that could be passed into |
The glmm
function can be used to fit a single generalized mixed model.
While this approach is meant to be used in the case where the user knows which
covariates belong in the fixed and random effects and no penalization is required, one is
allowed to specify non-zero fixed and random effects penalties using lambdaControl
and the (...) arguments. The (...) allow for specification of penalty-related arguments; see
glmmPen
for details. For a high dimensional situation, the user may want to fit a
minimal penalty model using a small penalty for the fixed and random effects and save the posterior
samples from this minimal penalty model for use in any BIC-ICQ calculations during selection within glmmPen
.
Specifying a file name in the 'BICq_posterior' argument will save the posterior samples from the
glmm
model into a big.matrix with this file name, see the Details section of
glmmPen
for additional details.
A reference class object of class pglmmObj
for which many methods are
available (e.g. methods(class = "pglmmObj")
)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.