Comparison of the estimated baseline cumulative hazards functions for two survival models.
compHaz( fit1, fit2, main = NULL, lty = 1:2, col = c("red", "blue"), printLegend = TRUE )
| fit1 | An object of type "coxreg", "phreg", or other output from from survival fitters. |
|---|---|
| fit2 | An object of type "coxreg", "phreg", or other output from survival fitters. |
| main | Header for the plot. Default is |
| lty | line types. |
| col | Line colors. should be |
| printLegend | Should a legend be printed? Default is |
No return value.
Göran Broström
fit.cr <- coxreg(Surv(enter, exit, event) ~ sex, data = oldmort) fit.w <- phreg(Surv(enter, exit, event) ~ sex, data = oldmort) compHaz(fit.cr, fit.w)