plotKaplanMeier: generates Kaplan-Meier plot of survival probability as a...

plotKaplanMeierR Documentation

generates Kaplan-Meier plot of survival probability as a function of time

Description

For Cox regression models, this function generates a Kaplan-Meier plot of survival probability as a function of time for a given alpha. The default behavior is to partition the cohort in two groups by the predicted risk median, but custom partitions in two or more groups (specified by a vector of predicted risk percentiles) are also possible. In the former case, provided that the eNetXplorer object was generated with the logrank=TRUE argument, the corresponding cross-validated log-rank test p-value is displayed in the default title.

Usage

plotKaplanMeier(x, alpha.index=NULL, xlab="Time", ylab="Probability of Survival", 
cex.lab=1, main=NULL, col.main="black", cex.main=0.95, conf.int=TRUE,
breaks_ptiles=NULL, risk.col=NULL, legend=TRUE, legend.cex=0.75, ...)

Arguments

x

eNetXplorer object (must be family="cox").

alpha.index

Integer indices to select alpha values. Default is 1:length(alpha)

xlab

Custom x-axis label.

ylab

Custom y-axis label.

cex.lab

Axis label size.

main

Custom title.

col.main

Title color.

cex.main

Title size.

conf.int

Logical to display 95% confidence intervals. Default is TRUE.

breaks_ptiles

Vector of percentiles (in 0-1 range) to partition the cohort based on predicted risk. Default is 0.5.

risk.col

Vector of colors to display the predicted risk-based subcohorts.

legend

Logical to display legend. Default is TRUE.

legend.cex

Legend size.

...

Additional plotting parameters.

Author(s)

Julian Candia and John S. Tsang
Maintainer: Julian Candia julian.candia@nih.gov

See Also

eNetXplorer, plot

Examples


data(breastCancerSurv)
fit = eNetXplorer(x=breastCancerSurv$predictor, y=breastCancerSurv$response, family="cox", 
n_run=25, n_perm_null=15, seed=111, logrank=TRUE)
plot(x=fit, plot.type="KaplanMeier")
plotKaplanMeier(x=fit, alpha.index=6, conf.int=FALSE, breaks_ptiles=c(0.333,0.667))


juliancandia/eNetXplorer documentation built on May 11, 2023, 1:59 a.m.