coxph_plot: Survival plot for a given coxph model with one binary...

Description Usage Arguments Examples

View source: R/plot-pmtree.R

Description

Can be used on its own but is also useable as plotfun in node_pmterminal.

Usage

1
coxph_plot(mod, data = NULL, theme = theme_classic(), yrange = NULL)

Arguments

mod

A model of class coxph.

data

optional data frame. If NULL the data stored in mod is used.

theme

A ggplot2 theme.

yrange

Range of the y variable to be used for plotting. If NULL it will be 0 to max(y).

Examples

1
2
3
if(require("survival")) {
  coxph_plot(coxph(Surv(futime, fustat) ~ factor(rx), ovarian))
}

model4you documentation built on Dec. 6, 2019, 3 p.m.