Skip to main content
100%

A fast, serializable, Scala implementation of tDigest. Thrown together for a Spark project.

✓ Published0🌍 Public
RRobColeman
Last edited Jan 28, 2016
Created on Jan 27, 2016

This visualization demonstrates a serializable Scala implementation of the tDigest algorithm, designed for fast approximate quantile estimation in Apache Spark. It defines `Centroid` and `TDigest` case classes that use Scala’s mutable `TreeSet` for sorted centroid storage, with methods for updating, merging, compressing, and computing cumulative distribution and inverse CDF values. The code relies on `org.apache.spark.SparkContext` and `org.apache.commons.math3.distribution.ExponentialDistribution`, using `scala.util.Random` for centroid shuffling during merges.

AI-generated description

Similar vizzes