Intra-class correlation.
ICC calculates the intra-class correlation (ICC) from a fitted
hierarchical linear model using the 'nlme' or 'lme4' packages.
ICC(model, ...) ## S3 method for class 'lme' ICC(model, ...) ## S3 method for class 'merMod' ICC(model, ...)
model |
A fitted linear model of type 'lme' (nlme) or 'merMod' (lme4; linear, generalized, or nonlinear). |
... |
Not currently implemented; used to ensure consistency with S3 generic. |
The ICC is the proportion of variance that is between-person variance. For more information, see Hoyt & Kenny (2013).
The intra-class correlation of the model.
lme: Intra-class correlation for lme (nlme).
merMod: Intra-class correlation for lmer (lme4).
# iris data, showing use with lme()
if (require(nlme, quietly=TRUE)) {
model <- lme(Sepal.Width ~ 1, random=~1|Species, data=iris)
ICC(model) # .49 of variance is between-subjects
}
# iris data, showing use with lmer()
if (require(lme4, quietly=TRUE)) {
model <- lmer(Sepal.Width ~ 1 + (1|Species), data=iris)
ICC(model) # .49 of variance is between-subjects
}Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.