Trait PreciseStats

Source
pub trait PreciseStats<T>: Sized {
    // Required method
    fn add_prec(&mut self, elem: T, index: usize, sumc: &mut T, rmsc: &mut T);
}
Expand description

A trait for statistics which allows to add new values in a way so that the numerical uncertainty has less impact on the final results.

Required Methods§

Source

fn add_prec(&mut self, elem: T, index: usize, sumc: &mut T, rmsc: &mut T)

Adds a new values to the statistics using the Kahan summation algorithm described here: https://en.wikipedia.org/wiki/Kahan_summation_algorithm

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§