anova.glmgee | R Documentation |
Allows to compare nested generalized estimating equations using the Wald and generalized score tests.
## S3 method for class 'glmgee'
anova(
object,
...,
test = c("wald", "score"),
verbose = TRUE,
varest = c("robust", "df-adjusted", "model", "bias-corrected")
)
object |
an object of the class glmgee. |
... |
another objects of the class glmgee which are obtained from the fit of generalized estimating equations. |
test |
an (optional) character string indicating the required test. The available options are: Wald ("wald") and generalized score ("score") tests. As default, |
verbose |
an (optional) logical switch indicating if should the report of results be printed. As default, |
varest |
an (optional) character string indicating the type of estimator which should be used to the variance-covariance matrix of the interest parameters in the Wald test. The available options are: robust sandwich-type estimator ("robust"), degrees-of-freedom-adjusted estimator ("df-adjusted"), bias-corrected estimator ("bias-corrected"), and the model-based or naive estimator ("model"). As default, |
A matrix with three columns which contains the following:
Chi
The value of the statistic of the test.
df
The number of degrees of freedom.
Pr(>Chi)
The p-value of the test computed using the Chi-square distribution.
Rotnitzky A., Jewell P. (1990) Hypothesis Testing of Regression Parameters in Semiparametric Generalized Linear Models for Cluster Correlated Data. Biometrika 77:485-497.
Boos D.D. (1992) On Generalized Score Tests. The American Statistician 46:327-333.
Boos D. (1992) On Generalized Score Tests. American Statistician 46:327–33.
Rotnitzky A., Jewell N.P. (1990). Hypothesis Testing of Regression Parameters in Semiparametric Generalized Linear Models for Cluster Correlated Data. Biometrika 77:485-497.
###### Example 1: Effect of ozone-enriched atmosphere on growth of sitka spruces
data(spruces)
mod <- size ~ poly(days,4)
fit1 <- glmgee(mod, id=tree, family=Gamma(log), data=spruces, corstr="AR-M-dependent")
fit2 <- update(fit1, . ~ . + treat)
fit3 <- update(fit2, . ~ . + poly(days,4):treat)
anova(fit1,fit2,fit3,test="wald")
anova(fit3,test="wald")
###### Example 2: Treatment for severe postnatal depression
data(depression)
mod2 <- depressd ~ group
fit1 <- glmgee(mod2, id=subj, family=binomial(logit), corstr="AR-M-dependent", data=depression)
fit2 <- update(fit1, . ~ . + visit)
fit3 <- update(fit2, . ~ . + group:visit)
anova(fit1,fit2,fit3,test="score")
anova(fit3,test="score")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.