tdunning/t-digest — pull request #36 by jpountz (2014-12-30 15:16:42+00:00)
Title: Fix accuracy issues caused by floating-point rounding errors.

t-digests rely on the assumption that the average between x1 and x2 is
necessarily between x1 and x2 given that their weights are positive. This is
unfortunately not the case if x1 and x2 are close enough and the computation of
the average results in a loss of accuracy. ArrayDigest was particularly prone
to this issue given that on a given page, it sequentially searches for the
first centroid that is greater than or equal to the value to add, so on each
page, floating-point rounding errors can propagate to the left.

Here is the generated error.pdf without the fix
![error](https://cloud.githubusercontent.com/assets/299848/5579673/dd7cb522-903e-11e4-90d3-85ba5f758774.png)

And now with the fix applied
![error](https://cloud.githubusercontent.com/assets/299848/5579681/f53788a4-903e-11e4-9fa2-4c709f29ad29.png)

Close #25