public class MedianCalculator extends Object implements Function<double[],Double>
If the data are sorted from lowest to highest $(x_1, x_2, \dots, x_n)$, the median is given by $$ \begin{align*} m = \begin{cases} x_{\frac{n+1}{2}}\quad & n \text{ odd}\\ \frac{1}{2}\left(x_{\frac{n}{2}} + x_{\frac{n}{2} + 1}\right)\quad & n \text{ even} \end{cases} \end{align*} $$
| Constructor and Description |
|---|
MedianCalculator() |
Copyright 2009-Present by OpenGamma Inc. and individual contributors
Apache v2 licensed
Additional documentation can be found at strata.opengamma.io.