sigma2_u equals (MSbetween - MSwithin) / n (equation 7.6), the
intraclass correlation (7.7) and the LR chi square -2 (LL1 - LL2)
(7.8). Mirrors ca7e6 to ca7e8.
Usage
morie_hlm_components(
ms_between,
ms_within,
n_per_cluster,
ll_null = NA,
ll_full = NA
)
Arguments
- ms_between, ms_within
Mean squares.
- n_per_cluster
Cluster n
(harmonic mean under unequal sizes).
- ll_null, ll_full
Log-likelihoods.
Value
List with sigma2_u, icc, lr_chi2.
Examples
morie_hlm_components(ms_between = 40, ms_within = 10, n_per_cluster = 12,
ll_null = -520, ll_full = -505)
#> $sigma2_u
#> [1] 2.5
#>
#> $icc
#> [1] 0.2
#>
#> $lr_chi2
#> [1] 30
#>