I am looking to run a path analysis (two variables measured at two time points) using gsem. I also want to control for clustering by school. I have run the following code:
mi estimate, cmdok: gsem (grm_dst3 <- grm_dst1 [school_id]) (grm_disst3 <- grm_disst1 [school_id]) (grm_disst3 <- grm_dst1 [school_id]) ('grm_dst3' <- 'grm_disst1' [school_id]), ///
cov(M1[school_id]*M2[school_id]@0)
However, I am getting an error message:
' invalid name
an error occurred when mi estimate executed gsem on m=1
I am fairly new to STATA so I apologise if I am missing something obvious here.
Any guidance would be appreciated. Thanks!

0 Response to MI & GSEM
Post a Comment