| survfitr | R Documentation |
Computes an estimate of the survival curve of inter-occurrence times for recurrent event data, optionally by group, using the Peña-Strawderman-Hollander, the Wang-Chang or the gamma frailty MLE estimators, together with their standard errors.
survfitr(formula, data, type = "MLEfrailty", ...)
formula |
a formula object with a |
data |
a data frame in which to interpret the variables named in the formula. |
type |
a character string specifying the estimator:
|
... |
additional arguments passed to the fitting function of the chosen estimator. |
See psh_fit(), wc_fit() and mlefrailty_fit() for details on each
estimator; additional arguments in ... are passed to the chosen
fitting function.
A survfitr object: the fit of the chosen estimator, or a
named list with one fit per group when the formula defines groups.
Methods are provided for print, plot, lines and summary.
Peña, E.A., Strawderman, R. and Hollander, M. (2001). Nonparametric Estimation with Recurrent Event Data. Journal of the American Statistical Association 96, 1299–1315.
Wang, M.-C. and Chang, S.-H. (1999). Nonparametric Estimation of a Recurrent Survival Function. Journal of the American Statistical Association 94, 146–153.
print.survfitr(), plot.survfitr(), summary.survfitr(),
Survr(), psh_fit(), wc_fit(), mlefrailty_fit()
data(colon)
# fit a Peña-Strawderman-Hollander estimator by Dukes stage
fit <- survfitr(Survr(hc, time, event) ~ as.factor(dukes),
data = colon, type = "pena"
)
plot(fit, ylim = c(0, 1), xlim = c(0, 2000))
fit
summary(fit)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.