|
--- Andrew Kramer <akramer@CERNER.COM> wrote:
> I've been reading the HLM book by Raudenbush & Byrk and trying to
> replicate their methodology in SAS. Apparently PROC MIXED can run HLM
> but
> setting the correct class, model, and random statements is not
> straightforward.
>
> My initial model is a very simple one. I want to model hospital
> length of
> stay (hoslos). There are 120,000 patients (patid) within 100
> hospitals
> (hospnum). Each hospital is within one of 4 geographic regions
> (region).
> The level 1 effects are patients, the level 2 effects are hospitals,
> and
> the level 3 effects are regions. Hospitals and region are random
> effects.
> There is one fixed effect, age. I've tried the following statements
> with
> no luck:
>
> proc mixed data = test covtest;
> class hospnum region;
> model hoslos = age / solution ddfm=kr;
> random intercept / sub = hospitals(region);
> random intercept / sub = region;
> run;
>
> How should I be setting up my desired model in PROC MIXED? Also, the
> analyses I've tried take a very long time to run. Should I be using
> another estimation method than the default?
>
Is that actually the code that you submitted, or did you type
that code as you were posting to SAS-L. The reason that I ask
is that you declare the variable HOSPNUM on the class statement
and then use a variable HOSPITALS(region) on the first random
statement. If you submitted the code
proc mixed data = test covtest;
class hospnum region;
model hoslos = age / solution ddfm=kr;
random intercept / sub = hospnum(region);
random intercept / sub = region;
run;
then you need to tell us exactly what you mean when you say that
you've had "no luck" with your model. Note too that I might
question whether REGION should be a random effect or a fixed
effect. Are there other regions that you might make inference
to? If not, then region should be fixed in which case you would
have the model
proc mixed data = test covtest;
class hospnum region;
model hoslos = age region / solution ddfm=kr;
random intercept / sub = hospnum(region);
run;
Dale
---------------------------------------
Dale McLerran
Fred Hutchinson Cancer Research Center
mailto: dmclerra@NO_SPAMfhcrc.org
Ph: (206) 667-2926
Fax: (206) 667-5977
---------------------------------------
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
|