Trait peroxide::statistics::dist::RNG[][src]

pub trait RNG {
    fn sample(&self, n: usize) -> Vec<f64>;
fn pdf<S: PartialOrd + SampleUniform + Copy + Into<f64>>(&self, x: S) -> f64;
fn cdf<S: PartialOrd + SampleUniform + Copy + Into<f64>>(&self, x: S) -> f64; }

Random Number Generator trait

Methods

  • sample: extract samples

Required methods

fn sample(&self, n: usize) -> Vec<f64>[src]

Extract samples of distributions

fn pdf<S: PartialOrd + SampleUniform + Copy + Into<f64>>(&self, x: S) -> f64[src]

Probability Distribution Function

Type

f64 -> f64

fn cdf<S: PartialOrd + SampleUniform + Copy + Into<f64>>(&self, x: S) -> f64[src]

Cumulative Distribution Function

Type

f64 -> f64

Loading content...

Implementors

impl<T: PartialOrd + SampleUniform + Copy + Into<f64>> RNG for OPDist<T>[src]

RNG for OPDist

impl<T: PartialOrd + SampleUniform + Copy + Into<f64>> RNG for TPDist<T>[src]

RNG for TPDist

Loading content...