Description Usage Arguments Details Value References Examples
Returns hazard ratios and confidence intervals for each stratum.
1 | hazard.ratios(time, status, exposure, strata, method = "wald")
|
time |
a numeric vector of survival times. |
status |
a numeric vector of censoring indicators, with 0 = censored and 1 = dead. |
exposure |
a factor vector with two levels indicating exposure. The first level is assumed to be the exposed condition. |
strata |
a factor vector with at least two levels indicating strata. |
method |
method for calculating hazard ratio and confidence interval. Choices are "wald" (default) and "midp". |
Hazard ratios and their confidence intervals are calculated with the Wald
method using epitools::rateratio
. This can be changed to
median-unbiased estimation by setting method="midp"
.
A list containing a hazard ratio estimate and confidence interval for each stratum.
Newman (2001), page 208.
1 2 3 4 5 | ## Table 10.15 from Example 10.14
with(breast.survival, hazard.ratios(time, status, receptor.level, stage))
## using the "midp" method
with(breast.survival, hazard.ratios(time, status, receptor.level, stage, method="midp"))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.