Learn R Programming

gppm (version 0.3.0)

fitted.GPPM: Person-specific mean vectors and covariance matrices

Description

A fitted GPPM implies a mean vector and a covariance matrix for each person. These are returned by this function.

Usage

# S3 method for GPPM
fitted(object, ...)

Value

Returns a list structure with mean and covariances matrices. See example.

Arguments

object

object of class GPPM. Must be fitted, that is, a result from fit.GPPM.

...

additional arguments (currently not used).

See Also

Other functions to extract from a GPPM: SE(), coef.GPPM(), confint.GPPM(), covFun(), getData(), getIntern(), logLik.GPPM(), maxNObs(), meanFun(), nObs(), nPars(), nPers(), nPreds(), parEsts(), pars(), preds(), vcov.GPPM()

Examples

Run this code
# \donttest{
data("demoLGCM")
lgcm <- gppm(
  "muI+muS*t", "varI+covIS*(t+t#)+varS*t*t#+(t==t#)*sigma",
  demoLGCM, "ID", "y"
)
lgcmFit <- fit(lgcm)
meansCovs <- fitted(lgcmFit)

person1Mean <- meansCovs$mean[[1]]
person1Cov <- meansCovs$cov[[1]]
person1ID <- meansCovs$ID[[1]]
# }

Run the code above in your browser using DataLab