Skip to content
Prev 366723 / 398502 Next

Chi-square test

Dear Sergio,

You appear to have asked this question twice on r-help.

Anova() has no specific method for ?gls? models (I assume, though you don?t say so, that the model is fit by gls() in the nlme package), but the default method works and provides Wald chi-square tests for terms in the model. I don?t understand the model formula x ~ 1 + 2 + 3 + x, however, and so I have no idea what gls() would do with this model, other than report an error. Perhaps you can show us the output ? or, better yet, provide a reproducible example.

As a general matter, for 1-df terms in an additive model, the 1-df chi-square values reported by Anova() will simply be the squares of the corresponding Wald statistics (labelled ?t? I believe) reported in the summary of the model. Although the p-value is from the upper tail of the chi-square distribution, the test is inherently two-sided.

Best,
 John

-------------------------------------------------
John Fox, Professor
McMaster University
Hamilton, Ontario, Canada
Web: http::/socserv.mcmaster.ca/jfox