Order Statistics

Order Statistics

GraphIdx.StatsModule.

Some statistical functions, mainly related to (weighted) median computations.

source
permcumsum(w, pi)

Return the cumulative sums over w in order pi.

source
weighted_median(x, [w, [∂ ]])

Compute a generalized weighted order statistics. Hereby, we minimize

\[\min_{t} \sum_{i} w_i |t - x_i| + f(t)\]

whereby is the derivative of the convex function $f$ (by default constant 0 for ordinary weighted median).

Return the interval $[a, b]$ containing the minimizer (if unique $a = b$).

Todo

Compare the sorting to binary search and median strategies. Maybe use SIMD for median.

source