[R] Repeated measures by lme and aov give different results

Vicki Allison AllisonV at landcareresearch.co.nz
Tue Nov 14 22:59:52 CET 2006


I am analyzing data from an experiment with two factors: Carbon (+/-)
and O3 (+/-), with 4 replicates of each treatment, and 4 harvests over a
year.  The treatments are assigned in a block design to individual
Rings.

I have approaches this as a repeated measures design.  Fixed factors
are Carbon, O3 and Harvest, with Ring assigned as a random variable.  I
have performed repeated measures analysis on this data set two different
ways: one utilizing lme (as described in Crawley, 2002), and the second
using aov (based on Baron and Li, 2006).  Using lme I get very
conservative p-values, while aov gives me significant p-values,
consistent with those I obtain performing this analysis in SYSTAT.  Can
anyone explain how these models differ, and which is more appropriate to
the experimental design I have described?  The code I use, and the
output obtained follow:

1  lme model

library(nlme)
M5 <-lme(ln_tot_lgth ~ Carbon*O3*Harv., random = ~-1|Ring)
anova(M5, type="marginal")

# Output
                numDF denDF   F-value p-value
(Intercept)         1    44 176.59692  <.0001
Carbon              1    12   0.42187  0.5282
O3                  1    12   0.06507  0.8030
Harv.               1    44  17.15861  0.0002
Carbon:O3           1    12   0.23747  0.6348
Carbon:Harv.        1    44   0.85829  0.3593
O3:Harv.            1    44   0.04524  0.8325
Carbon:O3:Harv.     1    44   0.05645  0.8133
> plot(M5)


2  aov model

M6<-aov(ln_tot_lgth ~ O3*Harv.*Carbon + Error (Ring/Carbon+O3))
summary(M6)
plot(M6)

# Output
Error: Ring
          Df  Sum Sq Mean Sq F value  Pr(>F)  
O3         1 1.76999 1.76999  8.2645 0.01396 *
Carbon     1 0.64766 0.64766  3.0241 0.10760  
O3:Carbon  1 0.15777 0.15777  0.7366 0.40756  
Residuals 12 2.57002 0.21417                  

Error: Within
                Df Sum Sq Mean Sq F value   Pr(>F)    
Harv.            1 33.541  33.541 84.0109 9.14e-12 ***
O3:Harv.         1  0.001   0.001  0.0036   0.9524    
Harv.:Carbon     1  0.414   0.414  1.0362   0.3143    
O3:Harv.:Carbon  1  0.020   0.020  0.0508   0.8226    
Residuals       44 17.567   0.399   


*** Note change of location***

Victoria Allison
Landcare Research
Private Bag 92170
Auckland 1142
New Zealand
Phone: +64 9 574 4164
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
WARNING: This email and any attachments may be confidential ...{{dropped}}



More information about the R-help mailing list