Trait cgats::PartialAvg

source ·
pub trait PartialAvg<'a, T: 'a + PartialSum<'a, T> + PartialDiv<usize, Output = T>>: IterSum<'a, T> {
    // Provided method
    fn partial_avg(self) -> Option<T> { ... }
}
Expand description

Trait to average values in an iterator that may or may not be compatible

Provided Methods§

source

fn partial_avg(self) -> Option<T>

Try to average the values

Object Safety§

This trait is not object safe.

Implementors§

source§

impl<'a, T, I> PartialAvg<'a, T> for I
where I: IterSum<'a, T>, T: PartialSum<'a, T> + PartialDiv<usize, Output = T>,