pub fn diagnose_alignment(
data: &FdMatrix,
karcher: &KarcherMeanResult,
argvals: &[f64],
config: &DiagnosticConfig,
) -> Result<AlignmentDiagnosticSummary, FdarError>Expand description
Diagnose alignment quality for every curve after a Karcher mean computation.
For each curve the function computes warp complexity, smoothness, pre- and post-alignment residuals, and checks for non-monotone warps and insufficient improvement. Curves with any issue are flagged.
§Arguments
data— Original (unaligned) functional data (n x m).karcher— Result ofsuper::karcher::karcher_mean.argvals— Evaluation grid (length m).config— Diagnostic thresholds.
§Errors
Returns FdarError::InvalidDimension on shape mismatches.