Learn R Programming

survAUC (version 1.0-0)

predErr: Distance-based Estimators of Survival Predictive Accuracy

Description

Inverse-probability-of-censoring Weighted Estimators of Absolute and Squared Deviations between Survival Functions (Prediction Error Curves)

Usage

predErr(Surv.rsp, Surv.rsp.new, lp, lpnew, times, 
					type = "brier", int.type = "unweighted")

Arguments

Surv.rsp
A Surv(.,.) object containing to the outcome of the training data.
Surv.rsp.new
A Surv(.,.) object containing the outcome of the test data.
lp
The vector of linear predictors estimated from the training data.
lpnew
The vector of linear predictors obtained from the test data.
times
A vector of time points at which to compute the prediction error curve.
type
A string specifying the type of prediction error curve: 'brier' refers to the squared deviation between predicted and observed survival (Brier score), 'robust' refers to the absolute deviation between predicted and observed sur
int.type
A string specifying the type of the integration method for prediction error curves. Either 'unweighted' or 'weighted'.

References

Gerds, T. A. and M. Schumacher (2006). Consistent estimation of the expected Brier score in general survival models with right-censored event times. Biometrical Journal 48, 1029--1040. Schmid, M., T. Hielscher, T. Augustin, and O. Gefeller (2011). A robust alter- native to the Schemper-Henderson estimator of prediction error. Biometrics. To appear.

See Also

IntAUC, OXS, schemper

Examples

Run this code
TR <- ovarian[1:16,]
TE <- ovarian[17:26,]
train.fit  <- coxph(Surv(futime, fustat) ~ age,
                    x=TRUE, y=TRUE, method="breslow", data=TR)

lp <- predict(train.fit)
lpnew <- predict(train.fit, newdata=TE)
Surv.rsp <- Surv(TR$futime, TR$fustat)
Surv.rsp.new <- Surv(TE$futime, TE$fustat)
times <- 1:500                  

predErr(Surv.rsp, Surv.rsp.new, lp, lpnew, times, 
					type = "brier", int.type = "unweighted")

predErr(Surv.rsp, Surv.rsp.new, lp, lpnew, times, 
					type = "robust", int.type = "unweighted")

predErr(Surv.rsp, Surv.rsp.new, lp, lpnew, times, 
					type = "brier", int.type = "weighted")

Run the code above in your browser using DataLab