pub struct PrCurve {
pub points: Vec<PrPoint>,
pub average_precision: f64,
pub baseline: f64,
}Expand description
A precision–recall curve: operating points, average precision, and the positive-class prevalence (the curve’s chance baseline).
Fields§
§points: Vec<PrPoint>Operating points, ascending in recall.
average_precision: f64Average precision — the step-function area under the PR curve, using the
sum_n (R_n - R_{n-1}) * P_n definition (matching scikit-learn’s
average_precision_score), not a trapezoidal interpolation.
baseline: f64Positive-class prevalence, P / (P + N). A no-skill classifier’s PR
curve is a horizontal line at this height — the correct PR baseline (a
diagonal, which is the ROC baseline, would be wrong here).
Trait Implementations§
impl StructuralPartialEq for PrCurve
Auto Trait Implementations§
impl Freeze for PrCurve
impl RefUnwindSafe for PrCurve
impl Send for PrCurve
impl Sync for PrCurve
impl Unpin for PrCurve
impl UnsafeUnpin for PrCurve
impl UnwindSafe for PrCurve
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more