pub trait SummaryStatistics {
type Item: FromPrimitive;
type Output: NumOps<Self::Item>;
// Required methods
fn len(&self) -> usize;
fn product(&self) -> Self::Output;
fn sum(&self) -> Self::Output;
fn std(&self) -> Self::Output;
fn var(&self) -> Self::Output;
// Provided methods
fn elems(&self) -> Self::Item { ... }
fn is_empty(&self) -> bool { ... }
fn mean(&self) -> Self::Output { ... }
}Expand description
This trait describes the fundamental methods of summary statistics. These include the mean, standard deviation, variance, and more.
Required Associated Types§
Required Methods§
Provided Methods§
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".