@@ -30,39 +30,41 @@ def concordance_index_incidence(
3030 ``[2, 0, 1, 2]``, where 0, 1, 2 respectively denotes the censoring event, the event
3131 of interest and competing events.
3232
33- We define this C-index at time :math`\tau` as:
33+ We define this C-index at time :math: `\tau` as:
3434
3535 .. math::
3636
37- \mathrm{C}(t ) = \frac{\sum_{i=1}^n \sum_{j=1}^n (A_{ij}
38- \hat{W}_{ij, 1}^{-1} + B_{ij} \hat{W}_{ij, 2}^{-1}) Q^ {ij}(t )
39- N^1_i(t )}
37+ \mathrm{C}(\tau ) = \frac{\sum_{i=1}^n \sum_{j=1}^n (A_{ij}
38+ \hat{W}_{ij, 1}^{-1} + B_{ij} \hat{W}_{ij, 2}^{-1}) Q_ {ij}(\tau )
39+ N^1_i(\tau )}
4040 {\sum_{i=1}^n \sum_{j=1}^n (A_{ij}
41- \hat{W}_{ij, 1}^{-1} + B_{ij} \hat{W}_{ij, 2}^{-1}) N^1_i(t )}
41+ \hat{W}_{ij, 1}^{-1} + B_{ij} \hat{W}_{ij, 2}^{-1}) N^1_i(\tau )}
4242
4343 where:
4444
4545 .. math::
4646
4747 \begin{align}
48- N^1_i(t ) &= I\{T_i \leq t, D_i = 1\} \\
49- A_{ij} &= I\{T_i < T_j \cup (T_i =
50- T_j \cap D_j = 0)\} \\
51- B_{ij} &= I\{T_i \geq T_j, D_j = 2\} \\
52- \hat{W}_{ij,1} &= \hat{G}(T_i|X_i ) \hat{G}(T_i|X_j ) \\
53- \hat{W}_{ij,2} &= \hat{G}(T_i|X_i ) \hat{G}(T_j|X_j ) \\
54- Q_{ij}(t) &= I\{M(t, X_i ) > M(t, X_j )\}
48+ N^1_i(\tau ) &= I\{t_i \leq \tau, \delta_i = 1\} \\
49+ A_{ij} &= I\{t_i < t_j \cup (t_i =
50+ t_j \cap \delta_j = 0)\} \\
51+ B_{ij} &= I\{t_i \geq t_j, \delta_j = 2\} \\
52+ \hat{W}_{ij,1} &= \hat{G}(t_i| X = x_i ) \hat{G}(t_i|X = x_j ) \\
53+ \hat{W}_{ij,2} &= \hat{G}(t_i|X = x_i ) \hat{G}(t_j|X =x_j ) \\
54+ Q_{ij}(t) &= I\{F_k(\tau| X = x_i ) > F_k(\tau| X = x_j )\}
5555 \end{align}
5656
5757 where:
5858
59- - :math:`T_i` and :math:`D_i` are the observed time-to-event and event.
60- - :math:`D_j = 0, 1, 2` respectively denotes a censoring event,
61- the event of interest and competing events.
59+ - :math:`t_i` and :math:`\delta_i` are the observed time-to-event and event
60+ for the individual i.
61+ - :math:`\delta = 0, 1, 2` respectively denotes a censoring event,
62+ the event of interest and the competing events.
6263 - :math:`\hat{G}` is a IPCW estimator.
63- - :math:`Q_{ij}(t)` is an indicator for the order of predicted risk at :math:`t`.
64- - :math:`M` is the predicted cumulative incidence function for the event of
65- interest.
64+ - :math:`Q_{ij}(\tau)` is an indicator for the order of predicted risk at
65+ :math:`\tau`.
66+ - :math:`F_k` is the predicted cumulative incidence function for the event of
67+ interest k.
6668
6769 The concordance index (C-index) is a common metric in survival analysis that
6870 evaluates whether the model predictions correctly order pairs of individuals with
@@ -74,7 +76,7 @@ def concordance_index_incidence(
7476 first and when, following the formulas and notations in [Wolbers2014]_.
7577
7678 Due to the right-censoring in the data, the order of some pairs is unknown,
77- so we define the notion of comparable pairs, i.e. the pairs for which
79+ so we define the notion of comparable pairs, i.e. pairs for which
7880 we can compare the order of occurrence of the event of interest.
7981 A pair :math:`(i, j)` is comparable, with :math:`i` experiencing the event of
8082 interest at time :math:`T_i` if:
0 commit comments