Quantcast
Channel: Statalist
Viewing all articles
Browse latest Browse all 73293

Save level 2 residuals from gllamm

$
0
0
Dear Statalist,

I've run a model using gllamm, with an ordinal outcome (under/normal weight, overweight, obese), 2 levels (1 - individual, 2 - local authority district, LAD), and four covariates. The predicted value (logit) is 1 for every participant. Code as follows:

gllamm BMIcat ProfManP Male Bangla1664 NoCHnBP01comb, i(LAD) link(ologit) eform

I simply would like to save the level 2 residuals from the model. A search of the (rather limited) help documentation suggested gllapred is the command to use withgllamm for postestimation. However, I'm unsure which option should be used. The Stata help file (http://www.gllamm.org/gllapred.hlp) doesn't give the simple option of 'save level 2 residuals' - the description of options is in complicated terms that do not make much sense to a non-statistician like myself. The 'gllamm companion' (http://www.gllamm.org/gllamm_companion.pdf) suggests using gllapred residual1, ustd, which I've calculated, but is this what I am after? If yes, great - problem solved (please let me know this is correct).

However, the 'gllamm review by the University of Bristol' suggests that Pearson and Anscombe residuals could also be computed using gllapred residual2, pearson, or gllapred residual3, anscombe. But, 1) I get the error message 'must specify above() option for ordinal responses' and no residuals are calculated; and 2) How can I tell if the response distribution is normally distributed when the predicted logits equal 1 for everyone? There are also other options within gllapred which could potentially be used, but which I do not understand. The gllapred residual1, ustd is not described as an option for calculating 'residuals' but a 'standardized posterior mean'.

Any help with this would be very gratefully received. Apologies for poor wording or definition of the problem - happy to clarify/provide further info as required.

Thanks,

Alice Dalton

Viewing all articles
Browse latest Browse all 73293

Trending Articles