pub fn shape_mean(
data: &FdMatrix,
argvals: &[f64],
quotient: ShapeQuotient,
lambda: f64,
max_iter: usize,
tol: f64,
) -> Result<ShapeMeanResult, FdarError>Expand description
Compute the Karcher (Frechet) mean in the elastic shape space.
Pre-processes all curves according to the quotient type, then computes the Karcher mean on the preprocessed data.
§Arguments
data— Functional data matrix (n x m).argvals— Evaluation points (length m).quotient— Which transformations to factor out.lambda— Roughness penalty for alignment.max_iter— Maximum number of Karcher iterations.tol— Convergence tolerance.
§Errors
Returns FdarError::InvalidDimension if argvals length does not match m
or n < 1.