Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

relRisk

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 geese

id

same as in geese

waves

same as in geese

data

same as in geese

subset

same as in geese

contrasts

same as in geese

na.action

same as in geese

corstr

same as in geese

ncopy

the number of copies of the original data in constructing weight.

control

same as in geese

b

initial values for regression coefficients as in geese but more difficult to obtain due to the log link.

alpha

same as in geese

Value

An object of class "geese" representing the fit.

Author(s)

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)

geepack

Generalized Estimating Equation Package

v1.3-2
GPL (>= 3)
Authors
Søren Højsgaard [aut, cre, cph], Ulrich Halekoh [aut, cph], Jun Yan [aut, cph], Claus Ekstrøm [ctb]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.