risksetROC {risksetROC}R Documentation

Incident/Dynamic (I/D) ROC curve, AUC and integrated AUC (iAUC) estimation of censored survival data

Description

This function creates risksetROC from a survival data set

Usage

risksetROC(Stime, entry=NULL, status, marker, predict.time, method="Cox",
                       span=NULL, order=1, window="asymmetric", prop=0.5,
                       plot=TRUE, type="l", xlab="FP", ylab="TP",
                       ...)  

Arguments

Stime

For right censored data, this is the follow up time. For left truncated data, this is the ending time for the interval.

entry

For left truncated data, this is the entry time of the interval. The default is set to NULL for right censored data.

status

survival status, 1 if had an event and 0 otherwise

marker

marker

predict.time

time point of interest

method

either of "Cox", "LocalCox" and "Schoenfeld", default is "Cox"

span

bandwidth parameter that controls the size of a local neighborhood, needed for method="LocalCox" or method="Schoenfeld"

order

0 or 1, locally mean if 0 and local linear if 1, needed for method="Schoenfeld", default is 1

window

either of "asymmetric" or "symmetric", default is asymmetric, needed for method="LocalCox"

prop

what proportion of the time-interval to consider when doing a local Cox fitting at predict.time, needed for method="LocalCox", default is 0.5.

plot

TRUE or FALSE, default is TRUE

type

default is "l", can be either of "p" for points, "l" for line, "b" for both

xlab

label for x-axis

ylab

label for y-axis

...

additional plot arguments

Details

This function creates and plots ROC based on incident/dynamic definition of Heagerty, et. al. based on a survival data and marker values. If proportional hazard is assumed then method="Cox" can be used. In case of non-proportional hazard, either of "LocalCox" or "Schoenfeld" can be used. These two methods differ in how the smoothing is done. If plot="TRUE" then the ROC curve is plotted with the diagonal line. Additional plot arguments can be supplied.

Value

Returns a list of the following items:

eta

unique marker values for calculation of TP and FP

TP

True Positive values corresponding to unique marker values

FP

False Positive values corresponding to unique marker values

AUC

Area Under (ROC) Curve at time predict.time

Author(s)

Paramita Saha

References

Heagerty, P.J., Zheng Y. (2005) Survival Model Predictive Accuracy and ROC curves Biometrics, 61, 92 – 105

See Also

llCoxReg(), SchoenSmooth(), CoxWeights()

Examples

library(MASS)
data(VA)
survival.time=VA$stime
survival.status=VA$status
score <- VA$Karn
cell.type <- factor(VA$cell)
tx <- as.integer( VA$treat==1 )
age <- VA$age
survival.status[survival.time>500 ] <- 0
survival.time[survival.time>500 ] <- 500
fit0 <- coxph( Surv(survival.time,survival.status)
        ~ score + cell.type + tx + age, na.action=na.omit )
eta <- fit0$linear.predictor

ROC.CC30=risksetROC(Stime=survival.time, status=survival.status,
                    marker=eta, predict.time=30, method="Cox",
                    main="ROC Curve", lty=2, col="red") 

[Package risksetROC version 1.0.4.1 Index]