Trait changepoint::BocpdLike
source · pub trait BocpdLike<T> {
type Fx: Rv<T>;
type PosteriorPredictive: Rv<Self::Fx>;
// Required methods
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
Required Associated Types§
sourcetype PosteriorPredictive: Rv<Self::Fx>
type PosteriorPredictive: Rv<Self::Fx>
Type of predictive prior distribution
Required Methods§
sourcefn step(&mut self, value: &T) -> &[f64]
fn step(&mut self, value: &T) -> &[f64]
Update the run-length detector and return a sequence of run length probabilities.
sourcefn reset(&mut self)
fn reset(&mut self)
Reset internal state, new run-lengths will refer to steps after this point.
sourcefn pp(&self) -> Self::PosteriorPredictive
fn pp(&self) -> Self::PosteriorPredictive
Generate the posterior predictive distribution