Learn R Programming

mvord (version 1.1.1)

error_struct: Error Structures in mvord

Description

Different error.structures are available in mvord:

  • general correlation structure (default) cor_general(~ 1),

  • general covariance structure cov_general(~ 1),

  • factor dependent correlation structure cor_general(~ f),

  • factor dependent covariance structure cov_general(~ f),

  • equicorrelation structure cor_equi(~ 1),

  • covariate dependent equicorrelation structure cor_equi(~ S),

  • AR(1) correlation structure cor_ar1(~ 1), or

  • covariate dependent AR(1) correlation structure cor_ar1(~ S).

For more details see vignette.

Usage

cov_general(formula = ~1, value = numeric(0), fixed = FALSE)

cor_general(formula = ~1, value = numeric(0), fixed = FALSE)

cor_ar1(formula = ~1, value = numeric(0), fixed = FALSE)

cor_equi(formula = ~1, value = numeric(0), fixed = FALSE)

Arguments

formula

formula object

value

specifies values of the correlation (and variance) parameters. For cor_equi() and cor_ar1() it can be either a vector of correlations (in (-1,1)) of length one (same correlation for all subjects) or a vector of length equal to the number of subjects. For cor_general(), it can be either a vector of the lower triangular correlation matrix elements (same structure for all subjects) or a matrix with number of rows equal to the number of subjects. For cov_general(), it can be either a vector of the lower triangular covariance matrix elements (including the diagonal) (same structure for all subjects) or a matrix with number of rows equal to the number of subjects. Default is value = numeric(0) object. In this case the correlation parameters are initialized with zero (and variance parameters with 1 for cov_general)

fixed

logical specifying whether the parameters of the error structure should not be optimized in the procedure, but will be fixed to the values specified in the argument value. Defaults to fixed = FALSE.