Learn R Programming

JM (version 0.8-1)

dynC: Dynamic Discrimination Index for Joint Models

Description

It computes the dynamic discrimination index presented in Rizopoulos (2010).

Usage

dynC(object, ...)

## S3 method for class 'jointModel':
dynC(object, dt, data, idVar = "id", times = NULL, 
  nt = 10, simulate = FALSE, estimator = c("median", "mean"), 
  M = 10, validate = FALSE, B = 10, verbose = FALSE, ...)

Arguments

object
an object inheriting from class jointModel.
dt
a numeric value indicating the length of the interval of primary interest within which we want to distinguish between subjects who died within the interval from subjects who survived longer than that.
data
a data frame that contains all variables use in the fit of the joint model. This should include both the variables for the longitudinal and survival parts.
idVar
a character string identifying the variable in data that distinguishes between subjects.
times
at which time points to compute the AUCs in order to obtain the dynamic C index.
nt
the number of time points to compute the AUCs, if the number of unique visit times in the sample is greater than nt.
simulate
the simulate argument of survfitJM.
estimator
the estimator argument of survfitJM.
M
the M argument of survfitJM.
validate
logical; if TRUE the Bootstrap validated index is produced -- this feature is not yet implemented.
B
numeric value indicating how many Bootstrap samples to use -- this feature is not yet implemented.
verbose
logical; if TRUE information is printed after each Bootstrap sample -- this feature is not yet implemented.
...
extra arguments; currently none is used.

Value

  • An object of class dynC is a list with components,
  • AUCtA numeric matrix with the values of the Area Under the ROC Curve for the different time points.
  • dynCthe value of the dynamic C index.

Details

(Note: the following contain some math formulas, which are better viewed in the pdf version of the manual accessible at http://cran.r-project.org/web/packages/JM/JM.pdf.) Function dynC computes the following discrimination index $$\mbox{C}_{dyn}^{\Delta t} = \int \mbox{AUC}(t, \Delta t) \, \mbox{Pr} { {\cal E}(t, \Delta t) } \; dt \Big / \int \mbox{Pr} { {\cal E}(t, \Delta t) } \; dt,$$ where $$\mbox{AUC}(t, \Delta t) = \mbox{Pr} \bigl [ \pi_i(t + \Delta t \mid t) < \pi_j(t + \Delta t \mid t) \mid { T_i^* \in (t, t + \Delta t] } \cap { T_j^* > t + \Delta t } \bigr ],$$ and $${\cal E}(t, \Delta t) = \bigl [ { T_i^* \in (t, t + \Delta t] } \cap { T_j^* > t + \Delta t } \bigr ],$$ with $i$ and $j$ denote to randomly selected subjects, and $\pi_i(t + \Delta t \mid t)$ denotes the conditional survival probabilities calculated by survfitJM, calculated for different time windows $\Delta t$ specified by argument dt. Index $\mbox{C}_{dyn}^{\Delta t}$ is in the spirit of Harrell's $c$-index, that is for the comparable subjects (i.e., the ones whose observed event times can be ordered), we compare their dynamic survival probabilities calculated by survfitJM. As with Harrell's $c$-index, $\mbox{C}_{dyn}^{\Delta t}$ does not take into account censoring, and therefore is expected to mask the true discriminative capability of the joint model under heavy censoring.

References

Antolini, L., Boracchi, P., and Biganzoli, E. (2005). A time-dependent discrimination index for survival data. Statistics in Medicine 24, 3927--3944. Harrell, F., Kerry, L. and Mark, D. (1996). Multivariable prognostic models: issues in developing models, evaluating assumptions and adequacy, and measuring and reducing errors. Statistics in Medicine 15, 361--387. Rizopoulos, D. (2010). Dynamic predictions and prospective accuracy in joint models for longitudinal and time-to-event data. Biometrics, accepted.

See Also

survfitJM, rocJM, jointModel

Examples

Run this code
fitLME <- lme(sqrt(CD4) ~ obstime + obstime:(drug + AZT + prevOI + gender), 
    random = ~ obstime | patient, data = aids)
fitSURV <- coxph(Surv(Time, death) ~ drug + AZT + prevOI + gender, 
    data = aids.id, x = TRUE)
fit.aids <- jointModel(fitLME, fitSURV, timeVar = "obstime", 
    method = "piecewise-PH-GH")

# the following will take some time to execute...
C.JMaids1 <- dynC(fit.aids, dt = 2, data = aids, idVar = "patient")
C.JMaids1

C.JMaids2 <- dynC(fit.aids, dt = 6, data = aids, idVar = "patient")
C.JMaids2

C.JMaids3 <- dynC(fit.aids, dt = 8, data = aids, idVar = "patient")
C.JMaids3

Run the code above in your browser using DataLab