powered by
Plot Kaplan-Meier Curve against Population
plotKM(dataSurv, dataPop, type = c("exact", "approximate"))
ggplot object
Survival data
Population data
Type of test to conduct in order to display p-value
# load data data(dataSurv_small) data(dataPop_2018_2021) plotKM(dataSurv_small, dataPop_2018_2021, type = "exact")
Run the code above in your browser using DataLab