Enum rv::dist::CategoricalError[][src]

pub enum CategoricalError {
    NonFiniteWeight {
        ix: usize,
        ln: bool,
        weight: f64,
    },
    NegativeWeight {
        ix: usize,
        weight: f64,
    },
    WeightsDoNotSumToOne {
        ln: bool,
        sum: f64,
    },
    EmptyWights,
}

Variants

NonFiniteWeight

One or more of the weights is infinite or NaN

Show fields

Fields of NonFiniteWeight

ix: usizeln: boolweight: f64
NegativeWeight

One or more of the weights is less than zero

Show fields

Fields of NegativeWeight

ix: usizeweight: f64
WeightsDoNotSumToOne

The weights do not sum to 1

Show fields

Fields of WeightsDoNotSumToOne

ln: boolsum: f64
EmptyWights

Weights has not entries

Trait Implementations

impl Clone for CategoricalError[src]

impl Debug for CategoricalError[src]

impl Display for CategoricalError[src]

impl Error for CategoricalError[src]

impl PartialEq<CategoricalError> for CategoricalError[src]

impl StructuralPartialEq for CategoricalError[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> ToString for T where
    T: Display + ?Sized
[src]

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>,