Usage
survexp(formula, data, weights, subset, na.action, rmap, times,
method=c("ederer", "hakulinen", "conditional", "individual.h",
"individual.s"),
cohort=TRUE, conditional=FALSE,
ratetable=survexp.us, scale=1,
se.fit, model=FALSE, x=FALSE, y=FALSE)
Arguments
formula
formula object. The response variable is a vector of follow-up times
and is optional. The predictors consist of optional grouping variables
separated by the +
operator (as in survfit
), and is often
~1
, i.e., expe
data
data frame in which to interpret the variables named in
the formula
, subset
and weights
arguments.
weights
case weights. This is most useful when conditional survival for a known
population is desired, e.g., the data set would contain all unique
age/sex combinations and the weights would be the proportion of each.
subset
expression indicating a subset of the rows of data
to be used in the fit.
na.action
function to filter missing data. This is applied to the model frame after
subset
has been applied. Default is options()$na.action
.
rmap
an optional list that maps data set names to the ratetable names. See
the details section below.
times
vector of follow-up times at which the resulting survival curve is
evaluated. If absent, the result will be reported for each unique
value of the vector of times supplied in the response value of
the formula
.
method
computational method for the creating the survival curves.
The individual
option does not create a curve, rather it
retrieves the predicted survival individual.s
or cumulative
hazard individual.h
for each subje
cohort
logical value. This argument has been superseded by the
method
argument. To maintain backwards compatability,
if is present and TRUE, it implies method='individual.s'
.
conditional
logical value. This argument has been superseded by the
method
argument. To maintain backwards compatability,
if it is present and TRUE it implies method='conditional'
.
ratetable
a table of event rates,
such as survexp.uswhite
, or a fitted Cox model.
scale
numeric value to scale the results. If ratetable
is in units/day,
scale = 365.25
causes the output to be reported in years.
se.fit
compute the standard error of the predicted survival.
This argument is currently ignored. Standard errors are not a defined
concept for population rate tables (they are treated as coming from a
complete census), and for Cox models the calculation is ha
model,x,y
flags to control what is returned. If any of these is true, then the
model frame, the model matrix, and/or the vector of response times will be
returned as components of the final result, with the same names as the
flag arguments.