kaplanMeier(formula, data=sys.parent(), weights, subset, na.action, se.fit=T, conf.interval="log", coverage=0.95, control=kaplanMeier.control)
formula
,
subset
and
weights
. If this argument is missing, the variables should be in the search list.
weights
must be the same as the length of the response.
The weights must be nonnegative and it is strongly recommended that they be strictly positive, since zero weights are ambiguous.
If you need to assign zero weights to some observations, use the
subset
argument instead. By default, no weights are included in the model.
data
that should be used in the fit. By default, all rows are included.
subset
argument has been used. The default filter is
options()$na.action
.
se.fit=TRUE
. Note that standard errors cannot be calculated for Turnbull's generalization of the Kaplan-Meier estimate for interval censored data; for more details, see the references listed below.
"none"
for no confidence intervals;
2)
"identity"
for standard intervals
curve +- k*se(curve)
, where
k
is determined by
coverage
;
3)
"log"
for intervals based on the cumulative hazard or
log(survival)
; and
4)
"log-log"
for intervals based on the log hazard or
log(-log(survival))
.
The last type of confidence interval never extends past 0 or 1. By default,
conf.interval="log"
. Only enough of the string to uniquely identify it is necessary.
tolerance
,
maxit
, and
maxmsd
), as returned by
kaplanMeier.control
. See
kaplanMeier.control
for more details.
"fits"
and
"call"
.
The
fits
component is a matrix containing the Kaplan-Meier estimate.
In the matrix,
time1
is the lower endpoint of a survival interval,
time2
is the upper endpoint,
survival
is the probability of survival to
time2
,
std.err
(if present) is the estimated standard deviation of the survival probability, and
lower
and
upper
(if present) are the lower and upper confidence bounds for the probability of survival to
time2
.
Turnbull, B. (1974). Nonparametric estimation of a survivorship function with doubly censored data. Journal of the American Statistical Association 69: 169-173.
Turnbull, B. (1976). The empirical distribution function with arbitrarily grouped, censored, and truncated data. Journal of the Royal Statistical Society (Series B) 38:290-295.
kaplanMeier(censor(days, event) ~ voltage, data = capacitor2, weights = weights) kaplanMeier(censor(time, status) ~ group, data = leukemia)