Output twolevel logistic PreviousNext
Mplus Discussion > Multilevel Data/Complex Sample >
Message/Author
 Inga BEck posted on Thursday, August 14, 2008 - 3:05 am
Dear Authors

I am planning to use Mplus 5.0 for a twolevel logistic analysis with a binary dependent variable and ML-estimation.

In my model, the predictor variables are situated either on the within-level (x) or the between level (w) only. All within-level effects are fixed (no random slopes). Mplus Manual p. 407 shows how to transform logistic regression coefficient in various ways.

My question is whether these guidelines also apply for calculating odd ratios for between-level (cluster-level) predictors. Other than odd ratios for within-level predictors, such odd ratios are not automatically shown in the Mplus-output.

May I use Mplus-example ex9.3 for illustration. There is an unstandardised b-value of 1.269 for the logistic regression of u on between-level predictor w. W

ould it be correct to transform this coefficient by exp(1.269) = 3.55, meaning that “between clusters, the odds of u = category ‘a’ vs. u = category ‘b’ increase by factor 3.55 for each unit increase in w?

Many thanks for your comments
Inga
 Linda K. Muthen posted on Thursday, August 14, 2008 - 6:13 am
On the between level u is a random intercept. It is a continuous latent variable. The coefficient is a linear regression coefficient. It cannot be turned into an odds ratio.
 Inga BEck posted on Thursday, August 14, 2008 - 7:23 am
Ok, thank you. Yet now I have two follow up questions:

Q 1. For the hypothetical model described above, in principle I could also use the stdyx-standardised coefficient of between-level predictor w for interpretation?

Q 2. If I would use WLSMV instead of ML and thus estimate a probit regression, the intercept (threshold)of u would still be considered to be continous and again parameter estimates of between-level predictors would be linear regression coefficients, not probit-coefficients?


Thanks for your help
 Bengt O. Muthen posted on Thursday, August 14, 2008 - 8:39 am
Q1. Yes.

Q2. Yes.
 Inga BEck posted on Tuesday, August 19, 2008 - 3:07 am
Hello

Yet I don't fully understand the Mplus approach to twolevel modeling for categorical data with maximum likelihood (keeping wlsmv aside for a moment).

More specifically, Bryk and Raudenbush (2002, p.300f. ) give an example of a twolevel model with a dichotomous outcome including both level-1 and level-2 covariates.

Here the effects of both level-1 and level-2 covariates are expressed in logit coeffecients and odd ratios.

Obviously, while some statistical perspectives (and software programs used by Bry & Raudenbush, see also the example in the book by Joop Hox) use a logit link for both within- (level 1) and between (level-2) relations, Mplus proceeds in a way that allows for linear regression coefficients on level-2 .

I would be very grateful for more information just how (statistically, technically) Mplus treats varying intercepts (question 1) and slopes (question 2) in a twolevel framework with categorical dependent variable so that one can use linear regression (Not: logit) coefficients.

Question 3: Is there any recommendable literature on this question for applied researchers (perhaps 'below' the level of psychometrika)? Or examples of published articles using the Mplus approach?

Many thanks for your support!
 Bengt O. Muthen posted on Tuesday, August 19, 2008 - 7:42 am
Mplus modeling is the same as other programs doing 2-level ML for categorical data - and the interpretations are the same. Good that you gave a specific references to pages in the R & B book, which clarifies our discussion. Page 300 does talk about log-odds, but note that this concerns regression coefficients that appear in level-1. As an example gamma10=-0.492. From equation 10.13, beta1j = gamma10 where beta1j is the fixed slope for SES in the level-1 equation. When we say that level-2 regression coefficients are those of linear regressions (because the dependent variables on level 2 are continuous), we refer to the coefficients gamma00, gamma01, gamma02, and gamma03 in eqn 10.13. In that equation, the dependent variable is beta0j which is a continuous dependent variable and therefore the gamma's are regular linear regression coefficients.

Having clarified that, we see from eqn 10.12 that ultimately beta0j does affect etaij and therefore ultimately does affect the probability of the binary outcome.

So, R & B is a good and sufficient reference for this. I can't remember seeing a less technical one.
 Bengt O. Muthen posted on Tuesday, August 19, 2008 - 8:14 am
Just adding to the previous, when you insert beta0j into the level-1 equation and therefore consider etaij (the log-odds) as the dependent variable, then the gamma0's can be turned into log-odds interpretations. R & B shows an example of that for gamma03. So it is a function of which dependent variable one considers, beta0j or etaij.
 Sarah Hall posted on Thursday, September 08, 2011 - 11:32 pm
Hello,

I am modelling relationships between individual and group level predictors and a binary outcome (using TYPE=TWOLEVEL RANDOM). I would like to plot the significant cross-level 2-way and 3-way interactions as logistic curves. Is it possible to do this in MPlus? I have tried each of the commands: “TYPE is plot1;” “TYPE is plot2;” and “TYPE is plot3;” but these only allow me to create scatterplots and histograms.

Thank you
Sarah
 Linda K. Muthen posted on Friday, September 09, 2011 - 6:58 am
With PLOT3 all available plot options are given.
 Carolyn Anderson posted on Friday, February 24, 2012 - 11:41 am
Can Mplus fit (or be tricked into fitting) a 2-level random effects multinomial logistic regression model?

I have multiple imputations and weights. I have been successful in fitting binary and ordinal models to the data.
 Bengt O. Muthen posted on Friday, February 24, 2012 - 6:40 pm
No trick needed. On the Between level, c#1 c#2, etc are random intercepts.
 Terry Ng-Knight posted on Friday, April 10, 2015 - 7:25 am
Hi, I am trying to assess whether the level-1 binary variable best friend stability (bfstab) varies across 9 schools (cluster variable) based on school policies regarding friendships (level-2 binary variable frreq). I have opted to test this using the TWOLEVEL procedure, using the code below:

USEVARIABLES ARE School bfstab frreq;
MISSING ARE BLANK;
IDVARIABLE = IDnum;
CATEGORICAL = bfstab;
CLUSTER IS SCHOOL;
BETWEEN = frreq;

ANALYSIS:
TYPE IS TWOLEVEL;

MODEL:
%BETWEEN%
bfstab ON frreq;

I would be very grateful if you could help me regarding 3 questions.
1. Does this model code seem correct?
2. How do I interpret the unstandardised estimates for bfstab ON frreq?
3. I was confused as to why the unstandardised and SDYX p-values differed so much, is this indicative of a modelling error on my behalf? - output below:

MODEL RESULTS
Two-Tailed
Estimate S.E. Est./S.E. P-Value

Between Level

BFSTAB ON
FRREQ 0.351 0.160 2.190 0.029

STDYX Standardization
Two-Tailed
Estimate S.E. Est./S.E. P-Value

Between Level

BFSTAB ON
FRREQ 0.900 0.626 1.438 0.151
 Bengt O. Muthen posted on Friday, April 10, 2015 - 1:53 pm
You should not do two-level modeling with only 9 clusters. There should be at least 30-50.
 Emily S Goering posted on Sunday, February 03, 2019 - 12:35 pm
Can someone provide guidance on how the parameter estimates in these cases (two level logistic at level2) can be interpreted? I understand that they can not be transformed to OR at the second level but how do I interpret these coefficients at level-2 in meaningful ways? I haven't been able to find good examples of this.
 Bengt O. Muthen posted on Monday, February 04, 2019 - 1:24 pm
See our Short Course Topic 7 video and handout, starting with slide 60.
 Eftychia Stamkou posted on Monday, May 13, 2019 - 7:32 am
I am testing a 2-level logistic regression model with a nominal DV, 4 Level-1 covariates, and 1 Level-2 covariate.

I specified "OUTPUT: cinterval" and got CIs of all the logit estimates in the output. However, when I calculate the CIs of the logit estimates using the formula by Raudenbusch & Bryk (2002; p. 297; for 95% CIs: beta0j +-1.96*sqrt(u0j)), I get different results compared to the Mplus output.

Could you please help me understand why I get different CIs?

Many thanks!
 Bengt O. Muthen posted on Monday, May 13, 2019 - 3:56 pm
The CIs that Mplus gives you are the regular ones referring to the parameter estimate. So with a symmetric CI, you have

estimate +- 1.96* SE(estimate)

The CI that the R & B book refers to is not a regular CI for a parameter estimate, just an interval based on the estimated model; it draws on the estimates of two parameters. You can calculate that interval using the Mplus parameter estimates.
 Eftychia Stamkou posted on Tuesday, May 14, 2019 - 1:23 am
Thank you for explaining, Bengt.

I have a follow-up question: To estimate the CIs of the threshold based on the estimated model, I use the beta0j and u0j estimates.
How can I estimate the CIs of the other parameters, e.g., the logit of my L2 covariate, based on the estimated model?
 Bengt O. Muthen posted on Tuesday, May 14, 2019 - 4:47 pm
The CI for any parameter is given in the output if you request CINTERVAL. If you want to compute R & B's interval, you have to do it either by hand or using Model Constraint.
 Jilian Halladay posted on Saturday, June 08, 2019 - 6:00 am
Hello!

I am trying to do a 3level logistic model with cluster level variables using FIML. My output does not seem to be giving me the logit or log odds, so just wondering if someone can let me know how I an fix my code! Thanks so much

usevariables are male age esa blk other imm intent mhserv
assets int ext mhprob mhneed ef tsrelat tsrelat_m ef_m med_income size;
categorical are intent mhserv;
idvariable studID;
cluster= idschl j_class;
within= male age esa blk other imm assets
int ext mhprob mhneed ef tsrelat;
between= (idschl) tsrelat_m med_income size
(j_class) ef_m;

missing are all (999);

define:
center int ext age assets med_income size ef tsrelat tsrelat_m ef_m(grandmean);
analysis:
type=threelevel random;

Model:
%WITHIN%
intent mhserv on male age esa blk other imm assets
int ext mhprob mhneed ef tsrelat;
[male age esa blk other imm assets
int ext mhprob mhneed ef tsrelat];
!male age esa blk other2 imm assets
!int ext mhprbs mhneed ef ts;
%between idschl%
intent on tsrelat_m med_income size;
mhserv on tsrelat_m med_income size;
%between j_class%
intent on ef_m;
mhserv on ef_m;

output: cinterval;
 Bengt O. Muthen posted on Saturday, June 08, 2019 - 3:52 pm
I don't see your declaration of Categorical= but 3-level with categorical DV exists for only Bayes in Mplus and uses probit regression, not logit. If you look at your output segment called Summary of analysis, you will see that the Bayes estimator is turned on.
 Jilian Halladay posted on Sunday, June 09, 2019 - 7:47 am
Hi Dr. Muthen,

Under use variables I have:

categorical are intent mhserv;

Is this correct?

Thank you for the clarification re: use of the probit model as opposed to logit. Do you have any suggested readings or examples on how to interpret the output and compare to results from logit models?

Also, when I did a 3-level linear model, it automatically performed listwise deletion (i.e. FIML was not used by default). To ensure FIML, I have included estimates of the variable means WITHIN.

i.e.

[male age esa blk other imm assets
int ext mhprob mhneed ef tsrelat];

Is this correct?

Thanks in advance,
Jillian
 Bengt O. Muthen posted on Sunday, June 09, 2019 - 4:36 pm
Q1: Yes.

Q2: Our RMA book goes through this but there are many books on logit/probit. We also discuss this in our Short Course Topic 2 video and handout on our website.

Q3: Yes.
 Jilian Halladay posted on Monday, June 10, 2019 - 7:59 am
Hi Dr. Muthen,

Great thank you so much. The video/slides were very helpful.

For the third question from my previous post, do I also have to estimate means of the upper level variables for FIML or just the WITHIN? Right now, I have complete data on my upper level variables, but just wondering for future analyses where I may not? When I include the mean estimates at both school and class, I don't get any output (the model runs, and then no output comes up). When I run the model just estimating means WITHIN and at one of the two upper levels, it runs and provides output.


Also, I am not getting p-values for my models. Is this because you do not get p-values for probit models? Or is there an issue with my data?

I am currently getting the following error message: PROBLEM OCCURRED IN THE COMPUTATION OF THE POSTERIOR PREDICTIVE P-VALUE.
THIS MAY BE DUE TO A SINGULAR SAMPLE VARIANCE COVARIANCE MATRIX, SUCH AS
WITH ZERO SAMPLE VARIANCES.

Thanks again for all your help,
Jillian
 Bengt O. Muthen posted on Monday, June 10, 2019 - 9:56 am
Note that an observed variable has only 1 mean, not a mean on both Within and Between. A between-level variable has its (only) mean on Between.

Regarding your other questions, we have to see your full output to answer - send to Support along with your license number.
Back to top
Add Your Message Here
Post:
Username: Posting Information:
This is a private posting area. Only registered users and moderators may post messages here.
Password:
Options: Enable HTML code in message
Automatically activate URLs in message
Action: