Learn R Programming

Mmcsd (version 1.0.0)

cov_mmcsd: Fit covariance structered longitudinal model.

Description

Responsible for performing the modeling of the model's covariance matrix through the use of covariance structures.

Usage

cov_mmcsd(fit, fittingType, sigmaThetaExpr, optimParams)

Value

The fit model with class 'mmcsd.theta'.

Arguments

fit

A fit model with class 'mmcsd'

fittingType

A character with the fitting function type. See optins above

sigmaThetaExpr

A character with the covariance structure type or a list of expressions

optimParams

A list with configuration for optim function. 'Par' is required.

Examples

Run this code
# \donttest{
fit <- mmcsd(
 score ~ wave + ageg + ecacg + qualifg,
 waves = wave, ids = id,
 weights = weight, stratum = strata, cluster = cluster,
 data = example_data, sigma = "exchangeable"
)
fitTheta_ucm <- cov_mmcsd(fit,
 fittingType = "PML", sigmaThetaExpr = "UCM",
 optimParams = list(par = c(7, 5))
)
# }

Run the code above in your browser using DataLab