Struct rv::data::GaussianSuffStat[][src]

pub struct GaussianSuffStat { /* fields omitted */ }

Gaussian sufficient statistic.

Holds the number of observations, their sum, and the sum of their squared values.

Implementations

impl GaussianSuffStat[src]

pub fn new() -> Self[src]

pub fn from_parts_unchecked(n: usize, mean: f64, sx: f64) -> Self[src]

Create a sufficient statistic from components without checking whether they are valid.

pub fn n(&self) -> usize[src]

Get the number of observations

pub fn mean(&self) -> f64[src]

Get the sample mean

pub fn sum_x(&self) -> f64[src]

Sum of x

pub fn sum_x_sq(&self) -> f64[src]

Sum of x^2

Trait Implementations

impl Clone for GaussianSuffStat[src]

impl Debug for GaussianSuffStat[src]

impl Default for GaussianSuffStat[src]

impl From<&'_ Vec<f32, Global>> for GaussianSuffStat[src]

impl From<&'_ Vec<f64, Global>> for GaussianSuffStat[src]

impl<'a> From<&'a GaussianSuffStat> for DataOrSuffStat<'a, f32, Gaussian>[src]

impl<'a> From<&'a GaussianSuffStat> for DataOrSuffStat<'a, f64, Gaussian>[src]

impl PartialEq<GaussianSuffStat> for GaussianSuffStat[src]

impl StructuralPartialEq for GaussianSuffStat[src]

impl SuffStat<f32> for GaussianSuffStat[src]

impl SuffStat<f64> for GaussianSuffStat[src]

Auto Trait Implementations

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> Same<T> for T

type Output = T

Should always be Self

impl<SS, SP> SupersetOf<SS> for SP where
    SS: SubsetOf<SP>, 

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.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,