Skip to contents

Computes from reCovs the variance and correlation components of random effect covariance matrices.

Usage

mkVarCorr(sc, cnms, nc = lengths(cnms, use.names = FALSE),
          theta, nms = names(cnms), reCovs = NULL,
          is_lmm = NULL)

Arguments

sc

a numeric vector of length 1 giving the residual standard deviation for LMMs.

cnms

a list of character vectors giving component dimnames, used only to determine nc and nms if those are missing.

nc

an integer vector giving component dimensions (number of columns).

theta

a numeric vector giving covariance parameters (lower triangular entries of relative Cholesky factors in column-major order), used only to determine reCovs when that is missing.

nms

a character vector giving component names.

reCovs

a list of Covariance objects.

is_lmm

a logical indicating if the model is an LMM as opposed to a GLMM, determining if sc is used.

Value

A list of matrices.

See also