aif360.sklearn.metrics
.smoothed_selection_rate¶
-
aif360.sklearn.metrics.
smoothed_selection_rate
(y_true, y_pred, *, concentration=1.0, pos_label=1, sample_weight=None)[source]¶ Compute the smoothed selection rate, \(\frac{TP + FP + \alpha}{P + N + |R_Y|\alpha}\).
Parameters: - y_true (array-like) – Ground truth (correct) target values. Ignored.
- y_pred (array-like) – Estimated targets as returned by a classifier.
- concentration (scalar) – Dirichlet smoothing concentration parameter \(|R_Y|\alpha\) (must be non-negative).
- pos_label (scalar, optional) – The label of the positive class.
- sample_weight (array-like, optional) – Sample weights.
Returns: float – Smoothed selection rate.