Companion

Functions

Link copied to clipboard
fun fit(points: List<Pair<Long, Boolean>>, a: Int = Fit.LAPLACE): Isotonic

Blocks merge while a block's smoothed rate exceeds the next block's, where the rate is (hits + a) / (n + 2a). With a = 0 this is classic PAV; with a > 0 the output is monotone after smoothing, which plain PAV followed by smoothing would not guarantee.