LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous messageNext messagePrevious in topicNext in topicPrevious by same authorNext by same authorPrevious page (June 2011, week 3)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Mon, 20 Jun 2011 08:42:17 -0500
Reply-To:     Robin R High <rhigh@UNMC.EDU>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         Robin R High <rhigh@UNMC.EDU>
Subject:      Re: DF in mixed models with repeated measures
Comments: To: Nuria Chapinal <nchapinal@YAHOO.COM>
In-Reply-To:  <201106181308.p5IAkjjW010505@waikiki.cc.uga.edu>
Content-Type: text/plain; charset="US-ASCII"

For repeated model covariance structures, the kenward-roger option with ddfm=kr is often considered a better choice, so I would suggest entering it. DF computations are rather complex depending on the variances which depend on the option entered for type= , plus with both RANDOM (default is type=contain) and REPEATED (default is type=bw) statements further complicate the issue. Regarding 2 of your 4 selections, the one with a REPEATED having cov type=cs along with the RANDOM statement is not recommended because under positive covariance, they both produce the same CS matrix. And the one with type=un is estimating components for an 8x8 matrix which is likely imposing too severe of a structure, esp. with only 272 observations. I'd also look at results from type=ante(1) and arh(1) along with the first two and also consider which one produces the substantially smaller value for BIC.

Robin High UNMC

From: Nuria Chapinal <nchapinal@YAHOO.COM> To: SAS-L@LISTSERV.UGA.EDU Date: 06/18/2011 08:10 AM Subject: DF in mixed models with repeated measures Sent by: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>

Good morning!

I have a dataset with 34 cows, 10 belonging to the treat mast=1, 24 belonging to the treat mast=0. Each cow has 8 consecutive days of data (feeding time, in particular, in the example below). So, in total I have 272 obs. I want to consider day as continuous because I am interested in the slope. Match is a block that I considered random, and there are 10 different ones. Each block has a cow from the treatment mast=1, and from 1 to 3 from the treat mast=0. Every cow has a unique ID number, so I didn't nest in the repeated statement.

I ran the model 4 times, with different covariance structures. My question is: why are the residuals DF for day so different when I use the different structures? It looks like the difference is driven by the fact that in some cases, the total DF for the effect of day is 272-1, because each cow has 8 observations, and in some others the total DF for the effect of day is 34-1, because each cow has 1 single slope? What's the correct option? Should every cow contribute to multiple or 1 DF to the total DF of the day and day*mast effect? It day was class, they would contribute to multiple, but since day is continuous, I am confused. Why are the different covariance types dealing with DF so differently?

I can send the output by email.

The models are (toep yields the smaller AIC):

proc sort data=pilar; by cow day;

proc mixed data=pilar covtest cl noitprint noclprint ; class cow match mast; model min = day mast mast*day/ solution ddfm=satterth outp=p; repeated /subject=cow type=toep; random match; run;

proc mixed data=pilar covtest cl noitprint noclprint ; class cow match mast; model min = day mast mast*day/ solution ddfm=satterth outp=p; repeated /subject=cow type=ar(1); random match; run;

proc mixed data=pilar covtest cl noitprint noclprint ; class cow match mast; model min = day mast mast*day/ solution ddfm=satterth outp=p; repeated /subject=cow type=cs; random match; run;

proc mixed data=pilar covtest cl noitprint noclprint ; class cow match mast; model min = day mast mast*day/ solution ddfm=satterth outp=p; repeated /subject=cow type=un; random match; run;

Thanks!


Back to: Top of message | Previous page | Main SAS-L page