[][src]Trait changepoint::BocpdLike

pub trait BocpdLike<T> {
    type Fx: Rv<T>;
    type PosteriorPredictive: Rv<Self::Fx>;
    fn step(&mut self, value: &T) -> &[f64];
fn reset(&mut self);
fn pp(&self) -> Self::PosteriorPredictive;
fn preload(&mut self, data: &[T]); }

Trait for implementors of Bayesian online change-point detection

Associated Types

type Fx: Rv<T>

Type of type of distribution

type PosteriorPredictive: Rv<Self::Fx>

Type of predictive prior distribution

Loading content...

Required methods

fn step(&mut self, value: &T) -> &[f64]

Update the run-length detector and return a sequence of run length probabilities.

fn reset(&mut self)

Reset internal state, new run-lengths will refer to steps after this point.

fn pp(&self) -> Self::PosteriorPredictive

Generate the posterior predictive distribution

fn preload(&mut self, data: &[T])

Preload a seqeunce into the default suff stat

Loading content...

Implementors

impl<X, Fx, Pr> BocpdLike<X> for Bocpd<X, Fx, Pr> where
    Fx: Rv<X> + HasSuffStat<X>,
    Pr: ConjugatePrior<X, Fx, Posterior = Pr> + Clone,
    Fx::Stat: Clone
[src]

type Fx = Fx

type PosteriorPredictive = Mixture<Pr>

fn step(&mut self, data: &X) -> &[f64][src]

Update the model with a new datum and return the distribution of run lengths.

impl<X, Fx, Pr> BocpdLike<X> for BocpdTruncated<X, Fx, Pr> where
    Fx: Rv<X> + HasSuffStat<X>,
    Pr: ConjugatePrior<X, Fx, Posterior = Pr> + Clone,
    Fx::Stat: Clone
[src]

type Fx = Fx

type PosteriorPredictive = Mixture<Pr>

fn step(&mut self, data: &X) -> &[f64][src]

Update the model with a new datum and return the distribution of run lengths.

Loading content...