Skip to main content

bayesian_align_pair

Function bayesian_align_pair 

Source
pub fn bayesian_align_pair(
    f1: &[f64],
    f2: &[f64],
    argvals: &[f64],
    config: &BayesianAlignConfig,
) -> Result<BayesianAlignmentResult, FdarError>
Expand description

Perform Bayesian pairwise alignment of f2 to f1 via pCN MCMC on the Hilbert sphere.

Uses a preconditioned Crank-Nicolson (pCN) proposal in the tangent space of the identity warping function on the Hilbert sphere. The DP-optimal alignment serves as initialization.

§Arguments

  • f1 — Target curve (length m)
  • f2 — Curve to align (length m)
  • argvals — Evaluation points (length m)
  • config — MCMC configuration

§Errors

Returns FdarError::InvalidDimension if lengths don’t match or m < 2. Returns FdarError::InvalidParameter if config values are out of range.