Extract model summaries and GOF statistics for model object
Extract model summaries and GOF statistics for model object
Calculates various GOF statistics for model object including global chi-squared test statistic and AIC. Extract model-specific mean and variance structure, residuals and various predicitions.
gof(object,...)## S3 method for class 'lvmfit'gof(object, chisq=FALSE, level=0.90, rmsea.threshold=0.05,all=FALSE,...)moments(x,...)## S3 method for class 'lvm'moments(x, p, debug=FALSE, conditional=FALSE, data=NULL, latent=FALSE,...)## S3 method for class 'lvmfit'logLik(object, p=coef(object), data=model.frame(object), model=object$estimator, weights=Weights(object), data2=object$data$data2,...)## S3 method for class 'lvmfit'score(x, data=model.frame(x), p=pars(x), model=x$estimator, weights=Weights(x), data2=x$data$data2,...)## S3 method for class 'lvmfit'information(x,p=pars(x),n=x$data$n,data=model.frame(x), model=x$estimator,weights=Weights(x), data2=x$data$data2,...)
Arguments
object: Model object
...: Additional arguments to be passed to the low level functions
x: Model object
p: Parameter vector used to calculate statistics
data: Data.frame to use
latent: If TRUE predictions of latent variables are included in output
data2: Optional second data.frame (only for censored observations)
weights: Optional weight matrix
n: Number of observations
conditional: If TRUE the conditional moments given the covariates are calculated. Otherwise the joint moments are calculated
model: String defining estimator, e.g. "gaussian" (see estimate)
debug: Debugging only
chisq: Boolean indicating whether to calculate chi-squared goodness-of-fit (always TRUE for estimator='gaussian')
level: Level of confidence limits for RMSEA
rmsea.threshold: Which probability to calculate, Pr(RMSEA<rmsea.treshold)
all: Calculate all (ad hoc) FIT indices: TLI, CFI, NFI, SRMR, ...