HORIZON HASKELLDocslts/ghc-10.0.x77a86622026-10-31Search packagesCtrl K
Theme: |

GHC 10.0.0.20260917 · lts/ghc-10.0.x · 77a8662 · 2026-10-31

Modulestatistics-0.16.5.0Haskell2010

Statistics.Sample.Normalize

Functions for normalizing samples.

Synopsis
valuestandardize :: Vector v Double => v Double -> Maybe (v Double)

O(n) Normalize a sample using standard scores:

z = \frac{x - \mu}{\sigma}

Where μ is sample mean and σ is standard deviation computed from unbiased variance estimation. If sample to small to compute σ or it's equal to 0 Nothing is returned.