[R] lm and anova

Paul Chatfield p.s.chatfield at reading.ac.uk
Thu May 12 15:30:59 CEST 2011


anova uses sequential sums of squares (type 1), summary adjusted sums of
squares (type 3)

Take for example the first line of each output.  In summary this tests
whether vole1 is needed ASSUMING volelag and year are already in the model
(conclusion would then be: it isn't needed p=.89).  Whereas in anova, it's
testing do we need vole1 assuming nothing else is in the model (conclusion:
vole1 is better than nothing. p=.0009).

anova assumes all terms above it are in the model but terms below it are not
so volelag assumes vole1 is in the model but not year.  You can see how
anova changes but summary doesn't by varying the order you put them in.

so the final model I would fit here would probably end up being either
year+volelag or just year,

HTH,

Paul

--
View this message in context: http://r.789695.n4.nabble.com/lm-and-anova-tp3516748p3517356.html
Sent from the R help mailing list archive at Nabble.com.



More information about the R-help mailing list