Greetings R-users,

This will be very obvious to some of you.  I have a nested field experiment:
a fixed factor treatment (location: 5 levels) is nested within blocks
(patches) nested within three sites.  Blocks (patches) and sites are random
factors.  I am interested in both site (random) and location (fixed)
effects, but the blocks (patches) are just replicates.  This is the code I
used:

test1 <- aov(ROUND2TOTAL ~ LOCATION*SITE + Error(PATCH/LOCATION), data=rain)

This is the summary with my interpretations in red:

Error: PATCH

          Df  Sum Sq Mean Sq F value  Pr(>F)  

SITE       2 0.58201 0.29100  3.8714 0.04409 *

Residuals 15 1.12752 0.07517                  

---

Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1 

This means that sites are significantly different, once you account for the
fact that each patch is nested within a site.

 

Error: PATCH:LOCATION

              Df  Sum Sq Mean Sq F value    Pr(>F)    

LOCATION       1 145.313 145.313  355.74 7.366e-12 ***

LOCATION:SITE  2   3.709   1.855    4.54   0.02873 *  

Residuals     15   6.127   0.408                      

---

Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1 

This means that locations differ (once you account for the fact that each
location factor is nested within a patch) but that the effects of the
location factor are not consistent among sites.

 

Error: Within

          Df Sum Sq Mean Sq F value Pr(>F)

Residuals 54 6.7467  0.1249         

 

Is this roughly correct or am I missing something altogether?  I have been
through Pinheiro & Bates 2000 and various other introductory texts but I am
still confused about the proper way of coding a nested design in R.

 

Thanks,

Jeremy 

 

 

Jeremy Lundholm, Ph.D.

Associate Professor

Biology/Environmental Studies

Saint Mary's University

Halifax, NS

B3H 3C3  Canada

902-420-5506

 <http://husky1.smu.ca/~jlundholm/about.htm>
http://husky1.smu.ca/~jlundholm/about.htm

 


	[[alternative HTML version deleted]]

