## Three-level model with two random slopes

Welcome to the forum for runmlwin users. Feel free to post your question about runmlwin here. The Centre for Multilevel Modelling take no responsibility for the accuracy of these posts, we are unable to monitor them closely. Do go ahead and post your question and thank you in advance if you find the time to post any answers!

Go to runmlwin: Running MLwiN from within Stata >> http://www.bristol.ac.uk/cmm/software/runmlwin/
johannesmueller
Posts: 11
Joined: Sun Jul 29, 2018 12:37 pm

### Three-level model with two random slopes

Dear all

I am trying to fit a (nested) three-level model with a three-way interaction, where there are constituent terms of the moderation at all three levels.
i.e. the response is observed at level 1 (binary), moderator1 at level1, moderator2 at level2, and moderator3 at level3. Moderators1 and 2 are group mean centered at level 3.

Now, I would want to allow the slopes of moderator1 and moderator2 to vary at level 3.

While it works with the diagonal restriction

Code: Select all

``runmlwin DV cons c.L##c.F##c.S  level3(level3: cons F S ,diagonal ) level2(level2: cons) level1(level1) discrete(distribution(binomial) link(logit) denom(cons)) nopause or zratio maxiterations(50000)``

once I take the diagonal restriction out -which I would want-

Code: Select all

``runmlwin DV cons c.L##c.F##c.S  level3(level3: cons F S ) level2(level2: cons) level1(level1) discrete(distribution(binomial) link(logit) denom(cons)) nopause or zratio maxiterations(50000)``
The result is that cov(cons,S), cov(F,S), and var(S) are returned as 0.
• How can I recover these parts of the model?

Thank you very much in advance!
ChrisCharlton
Posts: 1248
Joined: Mon Oct 19, 2009 10:34 am