Hi,
I am trying to extract the residuals from a cross-classified model I have estimated and match them back to their original LEA code, so I can draw a map of the residuals. I start by sorting the data by the classification from which I want to derive the residuals from. I then unreplicate the data, so that it goes back to its original (short) length. I then generate the residuals. My question is, how do I know when I 'view' the residuals alongside the LEAs, that the correct residuals are matched to the correct LEAs?
Many thanks,
Caroline.
Residuals - matching
-
- Posts: 1376
- Joined: Mon Oct 19, 2009 10:34 am
Re: Residuals - matching
For cross-classified models the residual number should correspond to the sorted ID numbers for that classification, i.e. if your classification is in column c1 and you wanted a short version in c2 to match the residual ordering then the command:
should give you a short ID column in the correct order.
Code: Select all
UNIQ c1 c2
Re: Residuals - matching
Great stuff. Thanks, Chris.
Re: Residuals - matching
I then unreplicate the data, so that it goes back to its original (short) length. I then generate the residuals.