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
)

Arguments

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 NULL.

lty

line types.

col

Line colors. should be NULL (black lines) or of length 2.

printLegend

Should a legend be printed? Default is TRUE.

Value

No return value.

See also

Author

Göran Broström

Examples

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)