relRisk {geepack} | R Documentation |
Fit a Relative Risk Model for Binary data with Log Link
Description
Fit a Relative Risk Model for Binary data with Log Link using the COPY method.
Usage
relRisk(
formula,
id,
waves = NULL,
data = parent.frame(),
subset = NULL,
contrasts = NULL,
na.action = na.omit,
corstr = "indep",
ncopy = 1000,
control = geese.control(),
b = NULL,
alpha = NULL
)
Arguments
formula |
same as in |
id |
same as in |
waves |
same as in |
data |
same as in |
subset |
same as in |
contrasts |
same as in |
na.action |
same as in |
corstr |
same as in |
ncopy |
the number of copies of the original data in constructing weight. |
control |
same as in |
b |
initial values for regression coefficients as in
|
alpha |
same as in |
Value
An object of class "geese"
representing the fit.
Author(s)
Jun Yan jyan.stat@gmail.com
References
Lumley, T., Kornmal, R. and Ma, S. (2006). Relative risk regression in medical research: models, contrasts, estimators, and algorithms. UW Biostatistics Working Paper Series 293, University of Washington.
Examples
## this example was used in Yu and Yan (2010, techreport)
data(respiratory)
respiratory$treat <- relevel(respiratory$treat, ref = "P")
respiratory$sex <- relevel(respiratory$sex, ref = "M")
respiratory$center <- as.factor(respiratory$center)
## 1 will be the reference level
fit <- relRisk(outcome ~ treat + center + sex + age + baseline + visit,
id = id, corstr = "ar1", data = respiratory, ncopy=10000)
summary(fit)
## fit <- relRisk(outcome ~ treat + center + sex + age + baseline + visit,
## id = id, corstr = "ex", data = respiratory)
## summary(fit)
## fit <- relRisk(outcome ~ treat + center + sex + age + baseline + visit,
## id = id, corstr = "indep", data = respiratory)
## summary(fit)
[Package geepack version 1.3.11 Index]