Class EmpiricalDistribution

java.lang.Object
io.nosqlbench.virtdata.library.basics.shared.from_long.to_double.Interpolate
io.nosqlbench.virtdata.library.basics.shared.from_long.to_double.EmpiricalDistribution
All Implemented Interfaces:
LongToDoubleFunction

public class EmpiricalDistribution extends Interpolate

This distribution is an easy-to use and modify distribution which is simply based on observed or expected frequencies. If you imagine drawing a line across a chart and then being able to use that to model frequencies, that is what this function does.

Values must be specified as x,y points, alternating. The x points draw a line segment from left 0.0 to right 1.0 on the unit interval, and the y points plot the magnitude. A LERP table with 1000 fixed points, which provides substantial precision for most systems testing purposes.

It is valid to have y values repeated, which is another way of saying that part of the sampled population will have identical values. x coordinates must be monotonically increasing, while y values may be any valid value, even out of order

  • Constructor Details

    • EmpiricalDistribution

      public EmpiricalDistribution(double... values)