plotKM {OneSampleLogRankTest}R Documentation

Plot Kaplan-Meier Curve against Population

Description

Plot Kaplan-Meier Curve against Population

Usage

plotKM(dataSurv, dataPop, type = c("exact", "approximate"))

Arguments

dataSurv

Survival data

dataPop

Population data

type

Type of test to conduct in order to display p-value

Value

ggplot object

Examples

# load data
data(dataSurv_small)
data(dataPop_2018_2021)

plotKM(dataSurv_small, dataPop_2018_2021, type = "exact")


[Package OneSampleLogRankTest version 0.9.2 Index]