SurvivalPlot: Create Kaplan-Meier plots

Description Usage Arguments Examples

View source: R/survplot_functions.R

Description

Create Kaplan-Meier plots

Usage

1
SurvivalPlot(fit, LegendTitle, timeUnit, colors, pval = NULL, max.year = NULL)

Arguments

fit

the resulting object from surival::survfit

LegendTitle

a string

timeUnit

a string (years, months, days, etc)

colors

a character vector of the same length as the number of groups in the KM plot

pval

an option string wit the pvalue

max.year

a numeric value to set x-axis limits.

Examples

1
2
fit <-  survival::survfit(survival::Surv(time, status) ~ x, data = survival::aml)
SurvivalPlot(fit=fit, LegendTitle="AML", timeUnit="months", colors=c("red","blue"))

jennylsmith/fusBreakpoint documentation built on Oct. 7, 2021, 8:04 p.m.