sksurv.metrics.concordance_index_censored¶

sksurv.metrics.
concordance_index_censored
(event_indicator, event_time, estimate, tied_tol=1e08)¶ Concordance index for rightcensored data
The concordance index is defined as the proportion of all comparable pairs in which the predictions and outcomes are concordant.
Samples are comparable if for at least one of them an event occurred. If the estimated risk is larger for the sample with a higher time of event/censoring, the predictions of that pair are said to be concordant. If an event occurred for one sample and the other is known to be eventfree at least until the time of event of the first, the second sample is assumed to outlive the first. When predicted risks are identical for a pair, 0.5 rather than 1 is added to the count of concordant pairs. A pair is not comparable if an event occurred for both of them at the same time or an event occurred for one of them but the time of censoring is smaller than the time of event of the first one.
See [1] for further description.
Parameters:  event_indicator (arraylike, shape = (n_samples,)) – Boolean array denotes whether an event occurred
 event_time (arraylike, shape = (n_samples,)) – Array containing the time of an event or time of censoring
 estimate (arraylike, shape = (n_samples,)) – Estimated risk of experiencing an event
 tied_tol (float, optional, default: 1e8) – The tolerance value for considering ties. If the absolute difference between risk scores is smaller or equal than tied_tol, risk scores are considered tied.
Returns:  cindex (float) – Concordance index
 concordant (int) – Number of concordant pairs
 discordant (int) – Number of discordant pairs
 tied_risk (int) – Number of pairs having tied estimated risks
 tied_time (int) – Number of comparable pairs sharing the same time
References
[1] Harrell, F.E., Califf, R.M., Pryor, D.B., Lee, K.L., Rosati, R.A, “Multivariable prognostic models: issues in developing models, evaluating assumptions and adequacy, and measuring and reducing errors”, Statistics in Medicine, 15(4), 36187, 1996.