Hi all,
I am attempting to run a cross-lagged panel model. I have two continuous variables (depression & body image dissatisfaction) at two time points. I also want to add a cluster variable for school. I am able to successfully run the basic model using the following code:
gsem (DS_1 -> ds_t1, ) (DS_1 -> DS_2, ) (DS_1 -> ED_2, ) (DS_2 -> ds_t3, ) ///
(ED_2 -> diss_t3, ) (ED_1 -> diss_t1, ) (ED_1 -> DS_2, ) (ED_1 -> ED_2, ), ///
covstruct(_lexogenous, diagonal) latent(DS_1 DS_2 ED_2 ED_1 ) reliab(ds_t3 .8 ds_t1 .8 diss_t3 .8 diss_t1 .8 ) nocapslatent
However, when I attempt to add the cluster variable for school using the following code:
gsem (DS_2 -> ds_t3, ) (DS_1 -> ds_t1, ) (DS_1 -> DS_2, ) (DS_1 -> ED_2, ) ///
(ED_2 -> diss_t3, ) (ED_1 -> diss_t1, ) (ED_1 -> DS_2, ) (ED_1 -> ED_2, ) (M1[school_id] -> ds_t3, ),
> covstruct(_lexogenous, diagonal) latent(DS_2 DS_1 ED_2 ED_1 M1 ) ///
reliab(ds_t3 .8 ds_t1 .8 diss_t3 .8 diss_t1 .8 ) nocapslatent from (b)
I get the following error message
Iteration 0: log likelihood = -5990.2821 (not concave)
cannot compute an improvement -- discontinuous region encountered
r(430);
Is anybody any to advise on how I may address this error?
Thank you!
Related Posts with Gsem
did_multiplegt cannot estimate treatment effect; prompt does not applyHello everyone, I am using the did_multiplegt command in order to perform some analyses for my thes…
stcrreg competing risk model with random interceptDear Stata community, I have run the Fine-Gray competing risk model using stcrreg and worked perfec…
Exporting IRR tableHello guys, I have a question related to exporting IRR table. The problem I have is that when I expo…
gsem with interaction termsMy co-author and I are using gsem for our empirical analysis, but we have problems with how to inter…
Doubt of the Cox modelHello everyone, I am doing my thesis which seeks to find the variables that influence the survival …
Subscribe to:
Post Comments (Atom)
0 Response to Gsem
Post a Comment