yrosseel/lavaan

lavResiduals() throws an error for some estimators when ordered = FALSE

reckak opened this issue · 1 comments

reckak commented

lavResiduals() throws an error for some estimators when ordered = FALSE (but residuals() does not). For example:

`library(lavaan)

HS.model <- ' visual =~ x1 + x2 + x3
textual =~ x4 + x5 + x6
speed =~ x7 + x8 + x9 '

fit <- cfa(HS.model,
estimator = "WLSMV",
ordered = FALSE,
data = HolzingerSwineford1939)

lavResiduals(fit)`

Throws an error
Error in lav_model_h1_information_firstorder(lavmodel = lavmodel, lavsamplestats = lavsamplestats, : lavaan ERROR: information = "first.order" not available for estimator ‘DWLS’

Thanks. Fixed now!