I have a rather stupid doubt that I could not solve on my own and I hope you could help me.
Where z_3 is a contextual effect, say GDP and level 1 IDs are individuals. I could find that it is not a random slope model but it just models the heteroskedasticity, do you have any references for this kind of commands?
Finally, in the case of a cross-level interaction am I obliged to insert the main effect of z_3? would the following model have a random slope?
Thank you for any suggestion you could provide.
Yes, your first code and interpretation is correct.
In your second code you should include the fixed effect of z3. Including z3 in the random part of the model allows the between-country variance to be a function of country characteristics z3. A heteroskedastic relationship. There is no random slope interpretation here. See Chapter 7 of the MLwiN User Manual (especially Section 7.2).
In you third code, yes you need to include the main effect of z3 in the fixed part of the model.
I don't know whether I can reproduce the error in a sample dataset.
the variable y_hat is produced for the exact double of the original observations. I guess its because I am using a multinomial model, not sure why though. I would need this prediction for computing the R-squared (Snijders and Bosker (2011) pag 311) but I do not think I can trust its variance, can I? Do you know any strategy for solving this error?
Thank you for your time and the incredible job you did with Mlwin.