phreg(formula = formula(data), data = parent.frame(),
na.action = getOption("na.action"), dist = "weibull", init, shape = 0,
control = list(eps = 1e-08, maxiter = 20, trace = FALSE),
singular.ok = TRUE, model = FALSE, x = FALSE, y = TRUE, center = FALSE)
options()$na.action
.exponential
can be obtained by choosing "weibull"
in combination with shape = 1
.eps
(convergence
criterion), maxiter
(maximum number of iterations), and
silent
(logical, controlling amount of output). You can
change any component without mention the other(s).c("phreg", "coxreg", "coxph")
with componentsNULL
if not).print.phreg
doesn't work if
threeway or higher order interactions are present. Use
print.coxph
in that case.Note further that covariates are internally centered, if center =
TRUE
, by this function,
and this is not corrected for in the output. This affects the estimate
of $\log(scale)$, but nothing else. If you don't
like this, set
center = FALSE
.
coxreg
and coxph
, but different
from the one used by survreg
.
The model is
$$S(t; a, b, \beta, z) = S_0((t/b)^a)^{\exp(z\beta)}$$
where S0 is some standardized survivor function.coxreg
, check.dist
, link{aftreg}
.data(male.mortality)
fit <- phreg(Surv(enter, exit, event) ~ ses, data = male.mortality)
fit
plot(fit)
fit.cr <- coxreg(Surv(enter, exit, event) ~ ses, data = male.mortality)
check.dist(fit.cr, fit)
Run the code above in your browser using DataLab