Log-linear effect parameterization PreviousNext
Mplus Discussion > Latent Variable Mixture Modeling >
 Fridtjof Nussbeck posted on Friday, February 15, 2008 - 2:43 am

Is it possible to change from the dummy-coded parameterization in loglinear models (with latent variables = LCA) to the effect coded parameterization?


 Linda K. Muthen posted on Friday, February 15, 2008 - 9:24 am
There is no option for this but you might be able to do this using MODEL CONSTRAINT.
 Fridtjof Nussbeck posted on Wednesday, February 20, 2008 - 6:40 am

I tried to use model constraints to change from dummy to effect coding. Yet, it did not work.

Is there a hidden way to refer to the last category of a variable?

If I understand correctly (and if it were possible to refer to the last category), effect-coding should be implemented by:

[X#1] (p1);
[X#2] (p2);
[X#3] (p3);

p1 + p2 = - p3;

where X is a nominal latent (class) variable with 3 categories.
Is there any other option?

Thanks again,

 Bengt O. Muthen posted on Wednesday, February 20, 2008 - 9:31 am
I am not sure what you are trying to do - it sounds like you are using X as an exogeneous latent class variable, but then you would not use parameterization=loglinear but logistic. There is not a way to refer to the last class.
 Fridtjof Nussbeck posted on Wednesday, February 20, 2008 - 9:45 am
Yes, I am using X as an exogeneous latent class variable (with four indicators). As I have a 2nd latent class variable (Y; with different indicators), I stick to the loglinear parameterization. There is no causal structure between the two variables.

I am still not sure about what Linda ment saying that I should be able to change to the effect coding using MODEL CONSTRAINT.
 Bengt O. Muthen posted on Wednesday, February 20, 2008 - 10:02 am
I think you are thinking about the relationship of the Mplus coding of the last category having its parameter fixed at zero vs the conventional parameterization in loglinear modeling of frequency tables where the sum of the parameters across all categories is restricted to zero. MODEL CONSTRAINT could perhaps be used for implementing the second parameterization by expressing the resulting logistic probabilities P = exp(term)/sum exp(term) in terms of the second parameterization, but it isn't clear how that should be done.
 Fridtjof Nussbeck posted on Wednesday, February 20, 2008 - 10:28 am
Yes, I am thinking about exactly this parameterization.

But wouldn't I need all expressions exp(term) to determine the logistic probabilities and, hence, also need to refer to the last (dummy=0) category in the MODEL CONSTRAINT?

Thanks a lot,

 Nicole R. Nugent posted on Sunday, October 26, 2008 - 12:34 pm
I recently used GMM to estimate symptom trajectories across 4 timepoints. I encountered estimation difficulties in attempts to add quadratic and square root terms. However, a reviewer stated:

"A straight-linear function of change is probably not realistic because in the extreme you are predicting negative symptoms. Very likely, the function does reach an asymptote at extreme values. It would seem that a model that reflected such behavior would provide a better fit to the data. I know you had trouble with power polynomials. Try the log of time instead. The resulting function will be linear in the log of time, but curvilinear in actual time."

I was unable to find an example of the log of time - what would the syntax be for this?

Thanks in advance!
 Bengt O. Muthen posted on Sunday, October 26, 2008 - 2:56 pm
That just changes the time scores. Instead of say 1, 2, 3 you use 0, 0.69, 1.10. See the Mplus Short Course handout for Topic 3, slides 116-117. So,

i s | y1@0 y2@0.69 y3@1.10;
 mpduser1 posted on Thursday, January 22, 2009 - 8:19 am
1. I've tried doing a multilevel multinomal logistic regression model in Mplus, using the following (Y is my dependent variable, X1-X3 are my independent variables):







Y on


I've noticed that in doing so, the results I obtain (parameters, cutpoints) are identical to those I get if I do a regular (i.e., nonhierarchical) multinomal logistic regression, except that I get larger SEs.

So, my question is, does specifying a multilevel multinomial logistic regression in Mplus currently only adjust the SEs for clustering, vs. doing any sort of EB calculations?

2. Is it possible to do loglinear analysis in Mplus with NOMINAL categorical variables? Example 7.15 in the Mplus 5.1 User's Guide appears to be for ordered categorical variables. Further, can loglinear models be done specifying TYPE=RANDOM MIXTURE;?
 Linda K. Muthen posted on Friday, January 23, 2009 - 11:15 am
1. It is correct that the standard errors are larger when taking non-independence of observations into account.

With TYPE=TWOLEVEL, you do not simply adjust the standard errors. You need to add y#1 y#2; etc. depending on the number of categories of your nominal variable to the between part of the MODEL command to obtain the variances of the random intercepts. Note that RANDOM is not needed for random intercepts only for random slopes.

2. Yes, Example 7.15 can have nominal variables. TYPE=RANDOM MIXTURE is allowed with loglinear models but I'm not sure why you would need it. RANDOM is for random slopes.
 mpduser1 posted on Wednesday, March 18, 2009 - 9:16 am
Is there a trick to specifying three-way interactions when doing LOGLINEAR analyses in Mplus?
 Tihomir Asparouhov posted on Friday, March 20, 2009 - 12:11 pm
Here is an example.

names = v1 v2 v3;
categorical = v1-v3;
classes = c1(2) c2(2) c3(2);

%overall% ! two-way interaction
c1#1 with c2#1;
c1#1 with c3#1;
c2#1 with c3#1;

model c1:
c2#1 with c3#1; ! three-way interaction

model c2:

model c3:
 mpduser1 posted on Friday, March 20, 2009 - 3:08 pm
Greatly appreciated, thanks very much.
Back to top
Add Your Message Here
Username: Posting Information:
This is a private posting area. Only registered users and moderators may post messages here.
Options: Enable HTML code in message
Automatically activate URLs in message