# NOT RUN {
data(rwm5yr)
glmrp <- glm(docvis ~ outwork + female + age + factor(edlevel),
family = poisson, data = rwm5yr)
summary(glmrp)
exp(coef(glmrp))
ml_p <- ml_glm(docvis ~ outwork + female + age + factor(edlevel),
family = "poisson",
link = "log",
data = rwm5yr)
summary(ml_p)
exp(coef(ml_p))
library(MASS)
glmrnb <- glm.nb(docvis ~ outwork + female + age + factor(edlevel),
data = rwm5yr)
summary(glmrnb)
exp(coef(glmrnb))
# }
# NOT RUN {
library(gee)
mygee <- gee(docvis ~ outwork + age + factor(edlevel), id=id,
corstr = "exchangeable", family=poisson, data=rwm5yr)
summary(mygee)
exp(coef(mygee))
# }
Run the code above in your browser using DataLab