pub trait SummaryStatistics{
type Item;
type Output;
// 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 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§
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§
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".