getReCovs: Extract Fitted Covariance Structures

getReCovsR Documentation

Extract Fitted Covariance Structures

Description

Returns a list with one covariance object for each random effect in the model. If the object is an old-style (pre-version 2.0.0) fitted model, it automatically converts all terms to Covariance.us objects (except for terms including double-bar ‘||’ notation, which are converged to Covariance.diag objects).

Usage

getReCovs(object)

Arguments

object

an R object of class merMod, i.e., as resulting from lmer(), or glmer(), etc.

Value

a list of covariance objects

Examples

  m1 <- lmer(Reaction ~ Days + (Days || Subject), sleepstudy)
  sapply(getReCovs(m1), "class")

lme4 documentation built on March 6, 2026, 1:07 a.m.