pub struct MacroMetrics {
pub mean: f64,
pub ci: ConfidenceInterval,
}Expand description
Macro-averaged metric with its bootstrap CI, as reported by a gate.
Fields§
§mean: f64Per-field macro mean (equal field weights).
ci: ConfidenceIntervalBootstrap CI over the field values (fields are the resampling unit — resampling rows would understate field-level variance).
Implementations§
Source§impl MacroMetrics
impl MacroMetrics
Sourcepub fn from_fields(values: &[f64], seed: u64) -> Result<Self, MetricError>
pub fn from_fields(values: &[f64], seed: u64) -> Result<Self, MetricError>
Macro-average a metric over fields, with the protocol bootstrap CI.
§Errors
MetricError::EmptyInput if no field values are given; propagates bootstrap
errors.
Sourcepub fn upper_bound(&self) -> f64
pub fn upper_bound(&self) -> f64
Upper CI bound — the value bound-style gate comparisons condition on.
Trait Implementations§
Source§impl Clone for MacroMetrics
impl Clone for MacroMetrics
Source§fn clone(&self) -> MacroMetrics
fn clone(&self) -> MacroMetrics
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for MacroMetrics
impl Debug for MacroMetrics
Source§impl<'de> Deserialize<'de> for MacroMetrics
impl<'de> Deserialize<'de> for MacroMetrics
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for MacroMetrics
impl PartialEq for MacroMetrics
Source§fn eq(&self, other: &MacroMetrics) -> bool
fn eq(&self, other: &MacroMetrics) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for MacroMetrics
impl Serialize for MacroMetrics
impl Copy for MacroMetrics
impl StructuralPartialEq for MacroMetrics
Auto Trait Implementations§
impl Freeze for MacroMetrics
impl RefUnwindSafe for MacroMetrics
impl Send for MacroMetrics
impl Sync for MacroMetrics
impl Unpin for MacroMetrics
impl UnsafeUnpin for MacroMetrics
impl UnwindSafe for MacroMetrics
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