Order of Predicted Residuals with Multiple 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/
Post Reply
erikruzek
Posts: 12
Joined: Tue May 21, 2019 3:57 pm

Order of Predicted Residuals with Multiple Random Slopes

Post by erikruzek »

Hi Chris, George, and everyone,

When running a model with multiple random slopes and getting the Empirical Bayes predictions, is there a way to tell how the newly produced residual variables map onto the intercept and slopes?

I am running the following model:

Code: Select all

runmlwin RIT time time2, level3(first_school: cons time time2) ///
level2(student: cons time time2, residuals(uc)) level1(obs: cons) nopause
Once MLwiN finishes running, I get six new variables corresponding to the residuals - uc0, uc1, and uc2. I assumed uc0 would be the intercept but it clearly is not given the range of values whereas it looks like uc2 gives the EB predictions for the intercept (cons). Is there a systematic way that MLwiN assigns the the variable names for residuals when transferring them to Stata?

Thanks,
Erik
ChrisCharlton
Posts: 1250
Joined: Mon Oct 19, 2009 10:34 am

Re: Order of Predicted Residuals with Multiple Random Slopes

Post by ChrisCharlton »

These should be the order that the parameters appear in the model equation. You can see this by removing the nopause option so that this is displayed prior to fitting the model. This ordering will usually match the order in which runmlwin processes the variables, so in your case as you do not have cons in the fixed part this should be time, time2, cons.
erikruzek
Posts: 12
Joined: Tue May 21, 2019 3:57 pm

Re: Order of Predicted Residuals with Multiple Random Slopes

Post by erikruzek »

Thanks, Chris. That makes sense. I can see why I was confused - I did not mean to exclude the intercept from the fixed part of the model! Had I included it there, then uc0 would have been the random intercept.
Post Reply