pub fn precision_recall_curve(
scores: &[f64],
labels: &[bool],
) -> Result<PrCurve, StatsError>Expand description
Compute a precision–recall curve from predicted scores and true binary
labels (true = positive class). Higher scores are “more positive”.
§Errors
StatsError::LengthMismatchif the inputs differ in length.StatsError::EmptyInputif empty.StatsError::NoPositiveLabelsif there are no positives, since recall is0/0. (Unlike ROC, PR does not require any negatives.)