I am implementing CFA at the moment and looking at the residuals of model to determine how to improve the model fit
When i take the raw scores from the model, i get residuals for everything
When i take a look at the standardized/z-score residuals, I can see
NA between some of the questions which have large residuals in the raw score
I would like to examine the standardized residuals because i know those residuals are statistically significant at 1.96 (p<0.05) and 2.58(p<0.01) Can anyone explain to me why the null values exist?
Below is a reproducible example where
x2 have raw residual scores of 0.126 but when i standardize them i get
# Stackoverflow Question library(lavaan) mydf <- HolzingerSwineford1939 # First Create the CFA model for both groups combined HS.model <- ' visual =~ x1 + x2 + x3 textual =~ x4 + x5 + x6' # Fit the model Standardizing on the latent variable fit <- cfa(HS.model, data = mydf, meanstructure = TRUE, std.lv = TRUE, estimator = 'MLR') # Get the standardized residuals res_raw <- residuals(fit, type = 'raw')$cov # Get the standardized residuals res <- residuals(fit, type = 'standardized')$cov