riskset: Incident/Dynamic (I/D) ROC curve, AUC and integrated AUC...

Description Usage Arguments Details Value Author(s) References Examples

Description

This function creates risk set at each unique failure time from a survival data set.

Usage

1
riskset(dat, entry=FALSE)

Arguments

dat

survival dataset with at least three variables: survival.times, survival.status and marker, in that order. The survival data set may have additional variables. In case of interval censored data, the first four columns are: entry time, exit time, status at exit and marker

entry

default is FALSE indicating right censored data. TRUE if left truncated data

Details

This function creates risk set at each unique failure time from a survival data set and is needed for llCoxReg(). The function can handle both right censored and interval censored data.

Value

Returns a new data set with columns as follows: start, finish, newStatus and other variables from the original dataset except survival time and status. The first two columns correspond to the start and end of time intervals considered and the newStatus corresponds to the survival status of the patient corresponding to this interval, i.e. the status is 1 if the patient had event during this interval (start, finish] and 0 otherwise. Note that the survival time need to be in ascending order.

Author(s)

Patrick J. Heagerty

References

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

Examples

1
2
3
4
5
library(MASS)
data(VA)
## need to order the data in ascending order of survival time
new.VA=VA[order(VA$stime),]
risket.VA=riskset(new.VA)

risksetROC documentation built on May 2, 2019, 3:15 p.m.