[][src]Struct ndhistogram::value::WeightedSum

pub struct WeightedSum<T = f64> { /* fields omitted */ }

ndhistogram bin value type that calculates a weight sum. It also provides methods to keep track of the sum of weights squared. This is used to provide estimates of the statistical error on the weighted sum. This performs a similar function to Sumw2 that ROOT users may be familiar with.

Implementations

impl<T: Copy> WeightedSum<T>[src]

pub fn new() -> Self where
    Self: Default
[src]

Factory method to create an unfilled (or zero-valued) WeightedSum.

pub fn get(&self) -> T[src]

Get the current value of the weighted sum.

pub fn variance(&self) -> T[src]

Estimate of the variance of the weighted sum value is the sum of the weights squared.

pub fn standard_deviation<O: Float>(&self) -> O where
    T: Into<O>,
    O: Float
[src]

Square root of the variance.

Trait Implementations

impl<T: Clone> Clone for WeightedSum<T>[src]

impl<T: Copy> Copy for WeightedSum<T>[src]

impl<T: Debug> Debug for WeightedSum<T>[src]

impl<T: Default> Default for WeightedSum<T>[src]

impl<T: Eq> Eq for WeightedSum<T>[src]

impl<T: Copy + Fill> Fill for WeightedSum<T>[src]

impl<T, W> FillWith<W> for WeightedSum<T> where
    T: FillWith<W> + Copy,
    W: Mul<Output = W> + Copy
[src]

impl<T: Hash> Hash for WeightedSum<T>[src]

impl<T: Ord> Ord for WeightedSum<T>[src]

impl<T: PartialEq> PartialEq<WeightedSum<T>> for WeightedSum<T>[src]

impl<T: PartialOrd> PartialOrd<WeightedSum<T>> for WeightedSum<T>[src]

impl<T> StructuralEq for WeightedSum<T>[src]

impl<T> StructuralPartialEq for WeightedSum<T>[src]

Auto Trait Implementations

impl<T> RefUnwindSafe for WeightedSum<T> where
    T: RefUnwindSafe
[src]

impl<T> Send for WeightedSum<T> where
    T: Send
[src]

impl<T> Sync for WeightedSum<T> where
    T: Sync
[src]

impl<T> Unpin for WeightedSum<T> where
    T: Unpin
[src]

impl<T> UnwindSafe for WeightedSum<T> where
    T: UnwindSafe
[src]

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.