I am running LCA with covariates and have a question that I hope you can help me to answer. I have simplified the syntax to state the problem more clearly. u1-u7 are the latent class indicators. x1 and x2 are covariates. There is missing data on x1, a measure of income. Using the following syntax, I have trouble with the plots. While histograms and scatterplots are available, the plots of "estimated probabilities for a categorical latent variable as a function of its covariates" are not available. If I run the syntax below without the portion of the MODEL statement "x1 on x2 x3 x4 x5" MPlus outputs the plots but does not estimate the missing values as x1 is then treated as an x-variable in the analysis. This leaves me with one main question. Is it possible to order the covariates, estimate missing values, and still obtain the probability plots? Do I need to hand calculate the probabilites from the coefficients as suggested on page 345- of the User Guide? Thank you for help with this.
VARIABLE: NAMES ARE u1-u7 x1-x5;
USEVARIABLES ARE u1-u4 x1-x5 ;
CATEGORICAL ARE u1-u7; MISSING ARE ALL (999); CLASSES = c (3);
ANALYSIS: TYPE IS MIXTURE MISSING; INTEGRATION=NUMERICAL ALGORITHM=MONTECARLO
MODEL: %OVERALL% C#1 ON x1 x2 x3 x4 x5; C#2 ON x1 x2 x3 x4 x5; x1 ON x2 x3 x4 x5
Thank you so much for your reply. These forums are a tremendous resource. I did as you suggested, and the model runs fine, but still MPlus does not produce the probability plots, only the histogram and scattergram.
I then realized another difference from the syntax in my message above, and the syntax in which MPlus produces the probability plots. If I remove x1 ON x2 x3 x4 x5 ; MPlus does not produce the plots.
If I continue and remove ALGORITHM=INTEGRATION; INTEGRATION=MONTECARLO; then MPlus produces the plots.
Is it the case that the probability plots are not available when using montecarlo integration?
If you are referring to the plot of "estimated probabilities for a categorical latent variable as a function of its covariates", then this plot is not available for models with numerical integration. Numerical integration would be necessary when covariates are selected and this cannot be done post-processing.
When I use a model with i s | y1@0y2@1y3@2; everything works well!! But, when I try to use my tscores (age1-age3) in the model like below, I have a problem with my output, the plots are not there anymore… Can you tell me what is the problem with this syntax, I tried all the possibility for series…
variable: names are id age1 age2 age3 onset y1 y2 y3; usevariables are age1-age3 y1-y3; tscores = age1-age3; classes = c(6); missing = . ;
analysis: type = mixture random missing; starts = 20 2;
I am running a LCA with and without covariates. I’ve conducted LCAs before with the Analysis command: type=mixture missing (to obtain FIML) and ALWAYS received all necessary output to do the necessary interpretation. Now with the covariate model, I’m not receiving the Results in Probability Scale output. Why might that be? Is it because of the mixture missing command? Or, is it some other reason? Thanks for your help.
I don't believe this has changed. If the categorical latent variable is regressed on a covariate (c ON x), you will obtain results in the probability scale. If a latent class indicator is regressed on a covariate (u ON x), results are not given in probability scale because they vary depending on the covariate value.
I have a 4-class LCA with both categorical and continuous covariates. The model runs just fine with the categorical covariates, but I get the following error message when I include any continuous covariates:
WARNING: THE BEST LOGLIKELIHOOD VALUE WAS NOT REPLICATED. THE SOLUTION MAY NOT BE TRUSTWORTHY DUE TO LOCAL MAXIMA. INCREASE THE NUMBER OF RANDOM STARTS.
Although I get this message, the output looks just fine and demonstrates no major problems. I have increased the starts and it makes no difference. Should I ignore the message, or am I missing something in my syntax maybe? Here is the syntax with just two categorical (drpyr2; cesd162) and one continuous (mage1) covariate.
Without replicating the best loglikelihood, you may have hit a local solution. You should increase the random starts.
I would also check that the variances of the continuous variables are not large. If they are, I suggest rescaling them by dividing them by a constant in the DEFINE command so that the variances are between one and ten.
If you continue to have problems, you should send the input, data, output, and your license number to email@example.com.
I am conducting a 3 class LCA with 13 binary outcomes and three covariates (n=2300). Class 3 serves as the reference group, so I get class 1 vs. class 3 and class 2 vs. class 3 in the output. The Alternative Parameterization is not provided so I do not get class 1 vs. class 2. I believe this is happening because I am using numerical integration (algorithm = integration). How do I specify my Mplus code to give me the class 1 vs. class 2 comparison?
When I try to run the LCA without the Algorithm=integration option, I get the following warning from Mplus: "This latent class regression requires numerical integration. Add algorithm=integration to the analysis command." I forgot to mention that my covariates are both categorical and continuous.
It seems as though I might have a issue similar to the one above described by Roxann.
I am in the process of developing an LTA, following the Nylund 2007 dissertation. I am at the point where I am adding covariates and distal outcomes to my models at each time point (the covariates being dichotomous and the one distal being continuous).
While my model for the baseline runs well, when I add covariates to my 2nd and 3rd time points, I get the following error messages:
*** ERROR The following MODEL statements are ignored: * Statements in the OVERALL class: C#1 ON GENDER2 C#1 ON ETHNICIT C#1 ON INJTYPEV C#2 ON GENDER2 C#2 ON ETHNICIT C#2 ON INJTYPEV *** ERROR One or more MODEL statements were ignored. These statements may be incorrect or are only supported by ALGORITHM=INTEGRATION.
The differences between the time points is that the baseline data is complete, and the other time points have missing data.
Is the missing data the problem, or am I doing something incorrectly?
Thank you for your response. I added the ALGORITHM=INTEGRATION command, and the models converge well.
I do have another question, though, that I wanted to ask. In the probability plots for my 3 class solution, I have clear high, medium, and low endorsing groups. However, in the probability plots, the low endorsing group is labeled as class 2 and the medium group is 3. Is there a way I can switch the classifications of groups 2 and 3?
I ask because in the odds ratios reported in the output under model results, I have the ratios for classes 1 and 2 for my three covariates. That would be okay, but, I want to report the odds ratios for classes 1 and 2, with class 2 being the medium class and not the low class. Is there a way in Mplus that I can specify which classes are defined as 1, 2, or 3?
Hi, I think I´ve got nearly the same problem like Roxanna (July 03, 2010). I am conducting a 3 class LCA with the following input: usevariables are klima2 mathe2 lit2 mig1 mig2_ HISEI AlterJ AlterK Anzahl m2_ Buecher; Cluster= code_num_3; missing are all (-999); classes = c(3);
Model: %OVERALL% c on mig1 mig2_ HISEI AlterJ AlterK Anzahl m2_ Buecher;
HISEI AlterJ AlterK Anzahl m2_ Buecher;
For using the FIML I list the variables in the model line and mplus asks me then to use Algorithm=integration (although the covariates should be imputed are not categorical). Imputation seems to work well but for the regression model I only get class 1 and class 2 vs. class 3 in the output. The Alternative Parameterization is not provided so I do not get class 1 and class 3 vs. class 2 etc. How do I specify my model to give me all comparisons? Thank you very much!
The reason you need numerical integration is that you mention the variances of the observed covariates in the MODEL command. If you remove these and the following statements you should get all parameterizations.
Hi Linda, thank you for your reply. If I remove the covariates in the MODEL command the imputation is not working and the classes identified differ from the original model without covariates. Is the only possibility not using the FIML to get all parameterizations? Thanks again!
Hi I'm running into a similar problem as described by Simone. Could you please tell what it is that I'm doing to require the integration and montecarlo? I need to see the alternative parameterizations for the model being specified.
USEVARIABLES ARE age Q2SEX Q41C Q41D Q41E Q60A Q60B Q60C black hispanic asian other;
CLASSES = c (5);
Categorical = black hispanic asian other Q2SEX Q41C Q41D Q41E Q60A Q60B Q60C;
Missing is all (999);
ANALYSIS: type = mixture ; process=4; ALGORITHM=INTEGRATION; integration=montecarlo;
%overall% c#1-c#4 on black hispanic asian other Q2SEX age;
OUTPUT: SAMP stand cint tech14 tech11;
TYPE IS PLOT3; SERIES IS Q41C Q41D Q41E Q60A Q60B Q60C(*);
Tait Medina posted on Thursday, August 16, 2012 - 9:00 pm
Is there a quick way to get the estimated probabilities that are plotted in the plot "Estimated probabilities for a categorical latent variable as a function of its covariates"? Or, is this something we just need to compute by hand? Thank you!
Hi, I am running a LCA model with continuous and categorical covariates. When using the FIML method, is it correct to interpret that the analysis includes data from participants who had data on at least one of the categorical indicators, unless they were missing data on one of the covariates? In other words, how does the FIML treat covariates with missing data?
The diagram referred to is a diagram of the model. These are not available for mixture models. Plots of results using the PLOT command are available.
Ari Mäkiaho posted on Wednesday, August 28, 2013 - 8:51 am
Kristen Lee posted on Tuesday, September 17, 2013 - 2:35 pm
Hi, I am estimating a 3 class LCA model with covariates. I am interested in plotting the estimated probabilities of one of the indicators of my latent classes (opppcare), conditional on a set of covariates. However, regardless of what extreme values I set the covariates to, there is no variation in the predicted probabilities of the latent class indicator variable (by class). I've pasted part of my program below. Am I doing something wrong? Thank you.
The covariates in your model influence the latent class probabilities, which in turn influence the indicator probabilities. Your model has no direct effects from covariates to indicators. So when you get a probability for an indicator by class, then the covariate has no further influence on this probability within that class.
I have two predictors (one measured variable and the other latent continuous variable) for a latent categorical variable (LCA: 4 classes). I obtained odds ratios with class 4 being a reference. Earlier when I entered just one measured predictor, mplus automatically provided alternative parameterization for odds ratios of all possible comparison pairs. However, once the additional latent predictor was added to my model, this alternative parameterization odds ratios were not generated. How can I obtain these?
Below is a part of my input. Thank you so much!
USEVARIABLES male pabpre3m pabprept3 eabpre3m WEB VIC_PSYCHd VIC_PHYSd VIC_SEXd VIC_INJd PERP_PSYCHd PERP_PHYSd PERP_SEXd PERP_INJd ;
Use the SVALUES option of the OUTPUT command to get input with the ending values as starting values. Change the class numbers to what you want and delete the means of the categorical latent variables. Use STARTS=0;
Hello, I am running a LCA model with a 3-step approach to estimate the effects of covariates on class membership. The covariates entered in the Auxiliary statement have missing data and Mplus is using list-wise deletion. Is there a way to estimate the missing data for the covariates when using the 3-step approach? If not, what is the alternative? Would creating a multiple imputed dataset be an option?