Date: Fri, 16 May 2008 04:34:33 -0700
Reply-To: Steve Denham <stevedrd@YAHOO.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Steve Denham <stevedrd@YAHOO.COM>
Subject: Re: Selecting the right error for split-plot repeated measures
Content-Type: text/plain; charset=iso-8859-1
Good morning Annie,
I added the L back in because there are folks there a lot better at this than me, so I'm sure we should get some additional comments. Looking through your GLM and MIXED code, I think I would try the following:
Proc mixed data = repeated;
class site bloc clone type year obs;
model height =
clone | type|year sht06 scp06/ddfm=kr;
repeated year/subject=obs type=un;
random bloc site site*bloc;
lsmeans clone*year/diff;
lsmeans clone*type/diff;
run;
With this model, the dataset should look something like:
site bloc clone type year obs height sht06 scp06
A 1 1 1 2006 1 30 25 8
A 1 1 1 2007 1 42 25 8
A 1 1 2 2006 2 28 19 7
A 1 1 2 2007 2 46 19 7
etc.
If the data looks somehow different, then the model needs to be modified. Right now, it looks like I confounded type and obs. If there are multiple obs within a type, then my code ought to be appropriate.
I use the Kenward-Rogers degrees of freedom adjustment on all repeated measures analyses that I do, so that shows up in the model statement as well.
Good luck.
Steve Denham
Associate Director, Biostatistics
MPI Research, Inc.
Remove spamblock from header, and replace with stevedrd to reply to me.
----- Original Message ----
From: "Annie.Desrochers@uqat.ca" <Annie.Desrochers@uqat.ca>
To: stevedrd@yahoo.com
Sent: Thursday, May 15, 2008 3:58:55 PM
Subject: RE: Selecting the right error for split-plot repeated measures
Hi Steve,
Thanks for your input (I am not sure that it is politically correct that I write directly to you...)
I have run the program using proc mixed:
Proc mixed data = repeated;
class site bloc clone type year obs;
model height =
site | bloc | clone | type sht06 scp06;
repeated year/subject=obs type=un;
random bloc site ;
*lsmeans clone*year;
*lsmeans clone*type;
run;
First, I am not familiar with the proc mixed, why I try to avoid using it
-----Message d'origine-----
De : Steve Denham [mailto:stevedrd@yahoo.com]
Envoyé : 15 mai 2008 13:22
À : Desrochers, Annie; SAS-L@LISTSERV.UGA.EDU
Objet : Re: Selecting the right error for split-plot repeated measures
I'll pare this down to the statement:
"I have tried proc mixed instead but I don't like the output it
provides."
Because PROC MIXED is ideal for a split plot analysis with covariates (and GLM most definitely is not, unless you make multiple runs), I wonder if maybe we couldn't generate the output you are looking for somehow. Could you say what you don't like?
As far as what you have, it appears to be "correct" in the sense that the proper error terms are being used to test effects. I would expect separate p values for your dependent variables, as you have not included a manova statement.
Still, I can't help but refer to page 131, ch 4.5 of SAS for Mixed Models, 2nd. ed. where the authors have a bold font statement: "we emphatically recommend against using PROC GLM to analyze split-plot experiments." The next several pages give specific examples of how standard errors of differences between means are incorrectly calculated under GLM.
Good luck, and let's see what we can produce from MIXED that will fill your needs.
Steve Denham
Associate Director, Biostatistics
MPI Research, Inc.
Remove spamblock from header, and replace with stevedrd to reply to me.
----- Original Message ----
From: Dess27 <annie.desrochers@UQAT.CA>
To: SAS-L@LISTSERV.UGA.EDU
Sent: Thursday, May 15, 2008 11:18:10 AM
Subject: Selecting the right error for split-plot repeated measures
Hello,
I've been scratching my head with this one for a while, I'm sure it's
easy but my pregnant brain is very foggy.
I have a split-plot design testing the growth of different types of
trees on three site. At each sites there are 3 blocks (replicates)
which were each divided into 4 plots, 1 for each poplar clone. Then
each clone was divided into 4 subplots to accomodate each of the 4
tree types. Growth was monitored over 2 years using initial height
(sht06) and inital caliper (scp06) as covariates.
So I did a repeated analysis with proc GLM:
proc glm data=typeplan;
class site bloc clone type;
model fht06 fht07=
site
block
site*block
clone
clone*site
clone*site*block
type
type*site
type*clone
type*site*clone
sht06
scp06;
repeated year 2;
random block site*block clone*site*block;
test h=site e=site*block;
test h=bloc e=site*block;
test h=clone e=site*block*clone;
test h=clone*site e=clone*site*block;
run;
The problem is that when I get the following output, I am not sure
that the error used to test for site and clone effects were the right
ones even though I specified in the program, because at the end it
gives me p values for fht06 fht07 seperatly:
The GLM Procedure
Repeated Measures Analysis of Variance
Tests of Hypotheses for Between Subjects
Effects
Valeur
Source DF Type III SS Carré
moyen F Pr > F
site 2 54614.919
27307.459 24.00 <.0001
bloc 2 1176.564
588.282 0.52 0.5963
site*bloc 4 66164.771
16541.193 14.54 <.0001
clone 3 406156.519
135385.506 119.01 <.0001
site*clone 6 90969.276
15161.546 13.33 <.0001
site*bloc*clone 18 100793.354
5599.631 4.92 <.0001
type 3 407987.315
135995.772 119.55 <.0001
site*type 6 30966.029
5161.005 4.54 0.0001
clone*type 9 67621.591
7513.510 6.60 <.0001
site*clone*type 18 26162.834
1453.491 1.28 0.1926
sht06 1 58817.666
58817.666 51.70 <.0001
scp06 1 23373.189
23373.189 20.55 <.0001
Error 1540 1751887.724 1137.589
________________________________________________________________________________________________
Le Système SAS 10:16
Thursday, May 15, 2008 11
The GLM Procedure
Repeated Measures Analysis of Variance
Univariate Tests of Hypotheses for Within Subject
Effects
Valeur
Source DF Type III SS Carré
moyen F Pr > F
year 1 56545.5176
56545.5176 187.30 <.0001
year*site 2 174203.2821
87101.6411 288.52 <.0001
year*bloc 2 2178.1777
1089.0889 3.61 0.0273
year*site*bloc 4 10941.8105
2735.4526 9.06 <.0001
year*clone 3 27362.2467
9120.7489 30.21 <.0001
year*site*clone 6 26112.2554
4352.0426 14.42 <.0001
year*site*bloc*clone 18 32708.0030
1817.1113 6.02 <.0001
year*type 3 6308.2891
2102.7630 6.97 0.0001
year*site*type 6 7973.8684
1328.9781 4.40 0.0002
year*clone*type 9 9986.6129
1109.6237 3.68 0.0001
year*site*clone*type 18 10236.4124
568.6896 1.88 0.0137
year*sht06 1 1372.1155
1372.1155 4.55 0.0332
year*scp06 1 240.3147
240.3147 0.80 0.3724
Error(year) 1540 464914.7959 301.8927
Le Système SAS 10:16
Thursday, May 15, 2008 13
The GLM Procedure
Dependent Variable: fht06
Tests of Hypotheses Using the Type III MS for site*bloc as
an Error Term
Valeur
Source DF Type III SS Carré
moyen F Pr > F
site 2 28918.73161
14459.36580 2.50 0.1980
bloc 2 2365.99402
1182.99701 0.20 0.8233
Tests of Hypotheses Using the Type III MS for site*bloc*clone
as an Error Term
Valeur
Source DF Type III SS Carré
moyen F Pr > F
clone 3 116831.5846
38943.8615 31.75 <.0001
site*clone 6 16937.7998
2822.9666 2.30 0.0797
Does that seem right???
I have tried proc mixed instead but I don't like the output it
provides.
Any suggestions are welcomed
Thanks!
Dess27