[R] anova function to test the difference between two coefficients in nlme package

shirley zhang shirley0818 at gmail.com
Tue Jan 22 16:38:26 CET 2008

Dear Dr. Bates, and R-help,

I've tried the anova function  to test the difference between two
coefficients, as shown on page 225 of your book "Mixed Effects Models
in S and S-Plus (Statistics and Computing)".

When I type:  anova( fm2BW.lme, L = c(TimeDiet2 = 1, TimeDiet3 = -1) )

I got the following error message:

Error: unexpected '=' in "anova( fm2BW.lme, L = c(Time:Diet2 ="

Could you tell me whether I miss anything?

> sessionInfo()
R version 2.6.0 (2007-10-03)

LC_COLLATE=English_United States.1252;LC_CTYPE=English_United
States.1252;LC_NUMERIC=C;LC_TIME=English_United States.1252

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base

other attached packages:
[1] nlme_3.1-85

loaded via a namespace (and not attached):
[1] grid_2.6.0     lattice_0.16-5


More information about the R-help mailing list