Fits a Cox proportional hazards regression model. Time dependent variables,
time dependent strata, multiple events per subject, and other extensions are
incorporated using the counting process formulation of Andersen and Gill.
mode of stepwise search, can be one of "both"
(default), "backward", or "forward".
scope
defines the range of models examined in the stepwise search.
This should be a list containing components upper and
lower, both formulae.
k
multiple of the number of degrees of freedom used for the penalty.
Only k = 2 gives the genuine AIC: k = log(nobs) is sometimes
referred to as BIC or SBC.
trace
if positive, information is printed during the running of
stepAIC. Larger values may give more information on the fitting
process.
steps
maximum number of steps to be considered.
Value
MLModel class object.
Details
Response Types:
Surv
Default values for the NULL arguments and further model details can be
found in the source link below.
# NOT RUN {library(survival)
library(MASS)
fit(Surv(time, status != 2) ~ sex + age + year + thickness + ulcer,
data = Melanoma, model = CoxModel())
# }