Hi, I want to use the monte carlo facility to generate data for two independent groups, and then fit a CFA model in each group. Here is some syntax that I wrote, which runs but does not properly set up the populations (i.e., the fixed parameter values are not as I specified). Can you tell me if I am on the right track with my syntax?
See mcex5.14.inp. You need a group-specific MODEL POPULATION command. You also need a colon after the first MODEL command. If you continue to have problems with this, send your output and license number to email@example.com.
It is put on the hard disk when the program is installed. Check Program Files/Mplus and you should see the examples. Each example in the user's guide has a Monte Carlo counterpart that was used to generate the data for the examples. All examples and Monte Carlo counterparts come on the Mplus CD. They are also available on the website.
Jisoo Ock posted on Monday, September 03, 2012 - 4:14 pm
I wanted to use the Monte Carlo function to generate data for two independent groups, and then conduct measurement invariance analysis on each of the generated data (e.g., a metric invariance analysis with indicator x1 serving as the referent indicator and rest of the indicator loadings constrained to be equal).
Is it possible to write a MODEL command so that the program generates the data and does the invariance analysis?
If you mean "can Mplus automatically do the chi-square testing of the invariance model against the non-invariance model" in a Monte Carlo run, the answer is no. People have done that via external Monte Carlo and matching up the replications by other programs, such as the R program MplusAutomation.
Tom Booth posted on Saturday, March 02, 2013 - 7:58 am
A quick question.Is it possible to request (either as output to be extracted or simply viewed) the population covariance matrices from which the data is generated in the Monte Carlo procedure when the population model is multi-group?
I am trying to determine the sample size for a four-group model with a single latent factor using effects coding for identification. [I want the factor to be scaled like the indicators.] The goal is to compare the latent means between groups.
When I generate the population data as usual (factor variance fixed to one, factor mean fixed to zero in Group 1) and specify MODEL with effects coding (factor loadings sum to one, interceps sum to zero, latent variances and means in all groups freely estimated), Mplus tells me that my model is not identified.
How can I incorporate the effects-coding approach into a Montecarlo model?
Thanks! I think I found the source of the problem.
Yue Yin posted on Thursday, January 03, 2019 - 1:42 pm
Montecarlo: name=u1-u6 x1; generate=u1-u6(1); categorical=u1-u6; ngroups=2; nobs=150 150; nreps=20; repsave=all; save=rep*.dat Model population: [x1@0]; x1@1; f by u1*9 u2*.7 u3*.6 u4*.8 u5*.7 u6*.6; f*1; f on x1*.5; u1*.3 u2*.3 u3*.3 u4*.3 u5*.3 u6*.3; [u1$1*-.15]; [u2$1*.25]; [u3$1*.15]; [u4$1*-.25]; [u5$1*-.10]; [u6$1*.10]; model population-g2: f by u2*.5 u3*.4 ;
Hi, I want use monte carlo to created a data which has loading difference across groups, but after I run it, error said the error can't be computed, model is not identified. I can't figure out what the problem: Parameter 19, Group G2: F THE CONDITION NUMBER IS -0.278D-17. Could you help me with it? Thank you.