Trait changepoint::BocpdLike[][src]

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]); }
Expand description

Trait for implementors of Bayesian online change-point detection

Associated Types

type Fx: Rv<T>[src]

Expand description

Type of type of distribution

type PosteriorPredictive: Rv<Self::Fx>[src]

Expand description

Type of predictive prior distribution

Required methods

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

Expand description

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

fn reset(&mut self)[src]

Expand description

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

fn pp(&self) -> Self::PosteriorPredictive[src]

Expand description

Generate the posterior predictive distribution

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

Expand description

Preload a seqeunce into the default suff stat

Implementors

impl<K> BocpdLike<f64> for Argpcp<K> where
    K: Kernel
[src]

type Fx = Gaussian

type PosteriorPredictive = NormalGamma

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

fn reset(&mut self)[src]

fn preload(&mut self, _data: &[f64])[src]

fn pp(&self) -> Self::PosteriorPredictive[src]

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]

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

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

type Fx = Fx

type PosteriorPredictive = Mixture<Pr>

fn reset(&mut self)[src]

fn pp(&self) -> Self::PosteriorPredictive[src]

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

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]

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

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

type Fx = Fx

type PosteriorPredictive = Mixture<Pr>

fn reset(&mut self)[src]

fn pp(&self) -> Self::PosteriorPredictive[src]

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