Skip to main content

center

Function center 

Source
pub fn center(data: &FdMatrix, dim: Dim) -> FdMatrix
Expand description

Center functional data by subtracting the mean function via a unified Dim dispatch.

The 2D path never diverged from the 1D one, so both Dim arms forward to [center_1d]. The dim argument makes caller intent explicit and provides a single future seam should a real 2D specialization ever be needed.

ยงArguments

  • data - Functional data matrix (n x m)
  • dim - Dimensionality selector (Dim::One or Dim::Two)