pub struct EnsembleStats<S: Scalar> {
pub n_samples: usize,
pub mean: S,
pub std: S,
pub variance: S,
pub min: S,
pub max: S,
pub percentiles: Percentiles<S>,
}Expand description
Statistics computed from an ensemble of trajectories.
Fields§
§n_samples: usizeNumber of samples
mean: SSample mean
std: SSample standard deviation
variance: SSample variance
min: SMinimum value
max: SMaximum value
percentiles: Percentiles<S>Percentiles (5th, 25th, 50th, 75th, 95th)
Implementations§
Source§impl<S: Scalar> EnsembleStats<S>
impl<S: Scalar> EnsembleStats<S>
Sourcepub fn from_samples(samples: &[S]) -> Option<Self>
pub fn from_samples(samples: &[S]) -> Option<Self>
Compute statistics from a vector of samples.
Sourcepub fn standard_error(&self) -> S
pub fn standard_error(&self) -> S
Compute standard error of the mean.
Sourcepub fn confidence_interval(&self, level: S) -> (S, S)
pub fn confidence_interval(&self, level: S) -> (S, S)
Compute confidence interval for the mean at given level (e.g., 0.95 for 95%).
Uses normal approximation (valid for large samples).
Trait Implementations§
Auto Trait Implementations§
impl<S> Freeze for EnsembleStats<S>where
S: Freeze,
impl<S> RefUnwindSafe for EnsembleStats<S>where
S: RefUnwindSafe,
impl<S> Send for EnsembleStats<S>
impl<S> Sync for EnsembleStats<S>
impl<S> Unpin for EnsembleStats<S>where
S: Unpin,
impl<S> UnsafeUnpin for EnsembleStats<S>where
S: UnsafeUnpin,
impl<S> UnwindSafe for EnsembleStats<S>where
S: UnwindSafe,
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more