I'm trying to build a covariance-based structural equation model , more precisely a mediation model, using both reflective and formative specifications of latent variables. The purpose of that mediation modal, is to verify if the association between SS and PTGtot is mediated by the mediators STRAP and STRAN (both mediators in the same model). We want to do that by considering SS and PTGtot as reflective constructs and STRAP and STRAN as formative constructs.
model<- lavaan::sem(model = "PTGtot=~PTGav+PTGnp+PTGro+PTGps+PTGsc SS=~SSSres+SSSris STRAP<~SAac+SAv+SApr+SAp+SAh+SAa+SAr STRAN<~SAsd+SAde+SAsu+SAbd+SAsb STRAP~meda*SS PTGtot~medb*STRAP STRAN~medc*SS PTGtot~medd*STRAN PTGtot~ dir*SS indirect1 := meda*medb indirect2 := medc*medd total := dir+indirect1+indirect2", data = SIM_final, estimator = "MLR", missing = "fiml")
When I tried the code above, it gave me no error message. But when I tried to verify my fit indices:
lavaan::summary(model, standardized = TRUE, fit.measures = TRUE, rsquare = TRUE, ci = TRUE)
It gives me the following message in output, while providing me my fit indices:
lavaan 0.6-10 did NOT end normally after 2333 iterations ** WARNING ** Estimates below are most likely unreliable
So, based on this post:How to use formative indicators in covariance-based SEM with lavaan? I tried the next code by fixing some parameters and estimating some covariances, arbitrarily:
model<- lavaan::sem(model = "PTGtot=~1*PTGav+PTGnp+PTGro+PTGps+PTGsc SS=~1*SSSres+SSSris STRAP<~1*SAac+SAv+SApr+SAp+SAh+SAa+SAr STRAN<~1*SAsd+SAde+SAsu+SAbd+SAsb STRAP~meda*SS PTGtot~medb*STRAP STRAN~medc*SS PTGtot~medd*STRAN PTGtot~ dir*SS SS ~~ 1*SS PTGtot ~~ 1*PTGtot indirect1 := meda*medb indirect2 := medc*medd total := dir+indirect1+indirect2", data = SIM_final, estimator = "MLR", missing = "fiml")
The model is identified, and I don't get any error message when I check my fit indices. But when I try to verify the modification indices:
lavaan::modindices(model, sort. = TRUE)
Its gives me the next message error:
Error in lavaan::modindices(model, sort. = TRUE) : lavaan ERROR: could not compute modification indices; information matrix is singular.
Does anyone knows how to fix the last error message ? I specify that none of my variables are perfectly correlated (r=1). I thought that the problem might be the missing values in some data (149 missing values) , but technically full information maximum likelihood estimation is suppose to help to "manage" the missing values (from what I understood).
Furthermore, let me know if anyone see a more intuitive way to write my syntax. This is my first mixed model with formative and reflective constructs, so it is quite possible that there is some things that I wrote something that is not necessary.