Skip to contents

Print method for variance-covariance objects

Usage

# S3 method for class 'VarCorr.galamm'
print(
  x,
  digits = max(3, getOption("digits") - 2),
  comp = c("Std.Dev.", "Variance"),
  corr = any(comp == "Std.Dev."),
  ...
)

Arguments

x

An object of class c("VarCorr.galamm", "VarCorr.merMod"), returned from VarCorr.galamm.

digits

Optional arguments specifying number of digits to use when printing.

comp

Character vector of length 1 or 2 specifying which variance components to print. Case sensitive. Can take one of the values "Std.Dev." and "Variance".

corr

Logical value indicating whether covariances or correlations should be printed.

...

Optional arguments passed on to other methods. Currently not used.

Value

The variance-covariance information is printed to the console and the argument x is silently returned.

References

batesFittingLinearMixedEffects2015galamm

See also

VarCorr.galamm() for the function creating the variance-covariance objects.

Other details of model fit: VarCorr(), coef.galamm(), confint.galamm(), deviance.galamm(), factor_loadings.galamm(), family.galamm(), fitted.galamm(), fixef(), formula.galamm(), llikAIC(), logLik.galamm(), nobs.galamm(), predict.galamm(), ranef.galamm(), residuals.galamm(), response(), sigma.galamm(), vcov.galamm()

Author

This function is derived from lme4:::print.VarCorr.merMod written by Douglas M. Bates, Martin Maechler, Ben Bolker, and Steve Walker.

Examples

# Linear mixed model with heteroscedastic residuals
mod <- galamm(
  formula = y ~ x + (1 | id),
  weights = ~ (1 | item),
  data = hsced
)

# Extract information on variance and covariance
VarCorr(mod)
#>  Groups   Name        Std.Dev. Variance
#>  id       (Intercept) 0.99400  0.98804 
#>  Residual             0.97964  0.95970