tried doing exactly this as shown as well by Hall & Clark (2023):
*All analyses were conducted in R, with the SEMs estimated using the lavaan package (Rosseel, 2012). Missing data were handled with multiple imputation using predictive mean matching in the mice package (van Buuren & Groothuis-Oudshorn, 2011). The semTools package (Jorgenson et al., 2023) was used to pool lavaan results across multiply-imputed datasets.
*
How can I accesss p-values and confidence intervals of the pooled lavaan results?
This is my current code:
# Split the completed imputed datasets into a list, excluding original data
mice.imp0 <- lapply(1:m, function(i) complete(imp_mids, action = i, include = FALSE))
# Fit SEM model to imputed datasets
model_pooled <- runMI(sem_model,
data = mice.imp0,
fun = "sem",
cluster = "SerialAuto",
meanstructure = TRUE)
# Summarize the pooled SEM model
summary(model_pooled)
parameterEstimates(model_pooled, standardized = TRUE)
However, my output shows something like in the screenshot I attached. enter image description here
I expected to see p-values and CI as well.
The
parameterEstimates()function is not a generic function, so it only works forclass?lavaanobjects. If you read theclass?lavaan.mihelp page, you will find available methods forlavaan.miobjects. You just have to use thesummary()function, and theoutput=argument can be used to print the output as a data frame would normally look. There is also aci=argument.