Description Usage Arguments Details Value Author(s) References Examples
Calculate prediction error curve.
1 2 3 4 |
time |
Vector of time points in data |
status |
Vector of event indicators in data |
tsurv |
Vector of time points corresponding to the estimated survival
probabilities in |
survmat |
Matrix of estimated survival probabilities; dimension should be length of tsurv x length of time |
tcens |
Vector of time points corresponding to the estimated censoring
probabilities in |
censmat |
Matrix of estimated censoring probabilities; dimension should be length of tcens x length of time |
FUN |
The error function, either |
tout |
Vector of time points at which to evaluate prediction error. If missing, prediction error will be evaluated at all time points where the estimate will change value |
formula |
Formula for prediction model to be used as in
|
censformula |
Formula for censoring model, also to be used as in
|
data |
Data set in which to interpret |
censdata |
Data set in which to interpret |
CV |
Boolean (default= |
progress |
Boolean (default= |
The censformula
is used to calculate inverse probability of censoring
weights (IPCW).
A data frame with columns
time |
Event time points |
Err |
Prediction error of model specified by |
Hein Putter H.Putter@lumc.nl
Graf E, Schmoor C, Sauerbrei W & Schumacher M (1999), Assessment and comparison of prognostic classification schemes for survival data, Statistics in Medicine 18, 2529-2545.
Gerds & Schumacher (2006), Consistent estimation of the expected Brier score in general survival models with right-censored event times, Biometrical Journal 48, 1029-1040.
van Houwelingen HC, Putter H (2012). Dynamic Prediction in Clinical Survival Analysis. Chapman & Hall.
1 2 3 4 5 6 7 8 9 10 11 12 13 | data(ova)
# Example on a subset, because the effect of CV is clearer
ova2 <- ova[1:100,]
pecox(Surv(tyears, d) ~ Karn + Broders + FIGO + Ascites + Diam, Surv(tyears, 1-d) ~ 1,
data = ova2, FUN="Brier", tout=seq(0,6,by=0.5))
pecox(Surv(tyears, d) ~ Karn + Broders + FIGO + Ascites + Diam, Surv(tyears, 1-d) ~ 1,
data = ova2, FUN="Brier", tout=seq(0,6,by=0.5), CV=TRUE, progress=TRUE)
pecox(Surv(tyears, d) ~ Karn + Broders + FIGO + Ascites + Diam, Surv(tyears, 1-d) ~ 1,
data = ova, FUN="Brier", tout=seq(0,6,by=0.5))
pecox(Surv(tyears, d) ~ Karn + Broders + FIGO + Ascites + Diam, Surv(tyears, 1-d) ~ 1,
data = ova, FUN="Brier", tout=seq(0,6,by=0.5), CV=TRUE, progress=TRUE)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.