Description Usage Arguments Details Value
Runs the MELSM model and returns an ICCier object.
1 |
formula |
Formula representing the model. See details. |
data |
Data frame containing all variables. |
... |
Arguments passed to |
ICCier
uses the mixed effects location scale model to estimate an unconditional
(intercept-only) or conditional location model with random effect of person.
The within-person variances (i.e., residual, or error variances) are log-linearly modelled from a set of observation-level and
person-level predictors, with coefficients γ.
The between-person variances are also log-linearly modelled from a set of person-level predictors,
with coefficients η.
The formula syntax is as follows:
For an unconditional model:
outcome | personID ~ Level_1_formula | Level_2_formula
For a conditional model:
outcome | personID ~ Level_1_formula | Level_2_formula | Level_1_conditional | Level_2_conditional
The model is implemented in a 'maximal' manner, meaning all level 1 effects are assumed to randomly vary and correlate. Moreover, all level 2 variables predict each level 1 parameter. This means you should not include cross-level interaction terms, because they are implicit in the model formulation. Level 1 or Level 2 interaction terms may be included.
For now, the Level 2 formula predicts both the level 1 scale parameters, as well as the level 2 random effect variances.
If you wish to only have person-specific ICCs, use 1
as the level 1 formula (intercept-only).
When using a conditional model, the default ICCs are "unadjusted".
In our case, the "unadjusted" ICC is still the random intercept variance divided by
the random intercept variance and error variance.
This makes sense, if the location model(s) are meant to be controlling variables.
If you wish to have the so-called adjusted ICC, use adjusted = TRUE
.
The adjusted ICC instead uses the expected variance due to all random factors,
divided by itself and the error variance.
The adjusted ICC is therefore the proportion of random variance due to the random factors.
This makes sense if the goal is to examine individual differences, and therefore examine the
random effects themselves.
ICCier object. List containing the model formula, data, stan_data, model fit, and mapping between original ID and numeric ID.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.