Testing for Partial Invariance

My research team is interested in testing a mediation model and comparing the coefficients of A paths (from IV to Mediators) as well as the coefficients of B paths (from Mediators to DV). To do so, we estimated a model without B paths and constrained all A paths to be equal and then compared the fit of that model to one where A paths were not constrained. Similarly, we tested a model (including A paths) where B paths were constrained versus one where they were not.
However, we want to test for partial invariance by relaxing each constraint one at a time to see which significantly differ and which do not. We believe the lavTestScore function (from lavaan) would allow us to do so, but we’re unsure whether this is possible in metaSEM or which function would facilitate such a test. We would appreciate any help on this issue!
In addition, because we are only interested in the A paths (without B paths or the direct effect of the IV on the DV) in the first test, we wanted to ask whether it was possible to fit a model that does not include a path to the DV or that does not make use of a variable included in the correlation matrix? We got an error message (when calling tssem2) that the model specifications imply a 7x7 correlation matrix but the pooled correlation matrix (output of tssem1) is an 8x8 matrix, so clarity on this issue would be appreciated as well!
Thank you!
John Aitken
Hi John,
Could you please post a reproducible example by including the data and R code?
Mike
Log in or register to post comments
In reply to Hi John, by Mike Cheung
Yes! I've attached data and
Also, following AdminNeale's advice, I've included the B paths in the model testing for invariance among A paths. Thanks for the helpful advice!
John
Log in or register to post comments
In reply to Yes! I've attached data and by j.aitken
Hi John,
Regarding your second question on using a different number of variables in the stage 2 analysis, a simple approach is to rerun the stage 1 analysis with the selected variables.
Another approach is to use the developmental version in Github (https://github.com/mikewlcheung/metasem), which includes a subset.variables argument. For example,
model <- '
ts ~ es
cp ~ es
sc ~ es
# Variance of exogenous variable (employment status)
es ~~ 1*es # Fix variance of IV to 1
'
RAM <- lavaan2RAM(model, obs.variables = c("es", "ts", "cp", "sc"))
random2 <- tssem2(random1_pd, RAM=RAM,
subset.variables = c(TRUE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE, FALSE),
model.name = "model with 4 variables")
summary(random2)
Log in or register to post comments
Why no B paths?
Log in or register to post comments