These methods tidy the coefficients of generalized estimating
equations models of the geeglm
class from functions of the
geepack
package.
# S3 method for geeglm
tidy(x, conf.int = FALSE, conf.level = 0.95,
exponentiate = FALSE, quick = FALSE, ...)
An object of class geeglm
, such as from geeglm
whether to include a confidence interval
confidence level of the interval, used only if
conf.int=TRUE
whether to exponentiate the coefficient estimates and confidence intervals (typical for log distributions)
whether to compute a smaller and faster version, containing
only the term
and estimate
columns.
Additional arguments to be passed to other methods. Currently not used.
All tidying methods return a data.frame
without rownames.
The structure depends on the method chosen.
tidy.geeglm
returns one row for each coefficient, with five columns:
The term in the linear model being estimated and tested
The estimated coefficient
The standard error from the GEE model
Wald statistic
two-sided p-value
If conf.int=TRUE, it also includes columns for conf.low and conf.high, computed with confint.geeglm (included as part of broom).
If conf.int=TRUE
, the confidence interval is computed with
the confint.geeglm
function.
While tidy
is supported for "geeglm" objects, augment
and
glance
are not.
If you have missing values in your model data, you may need to
refit the model with na.action = na.exclude
or deal with the
missingness in the data beforehand.
# NOT RUN {
if (require('geepack')) {
data(state)
ds <- data.frame(state.region, state.x77)
geefit <- geeglm(Income ~ Frost + Murder, id = state.region,
data = ds, family = gaussian,
corstr = 'exchangeable')
tidy(geefit)
tidy(geefit, quick = TRUE)
tidy(geefit, conf.int = TRUE)
}
# }
Run the code above in your browser using DataLab