Ticks topic

Generate representative values from a continuous interval.

Functions

nice(num start, num stop, num count) → (num, num) Ticks
Returns a new interval [niceStart, niceStop] covering the given interval [start, stop] and where niceStart and niceStop are guaranteed to align with the corresponding tickStep.
range({num start = 0, required num stop, num step = 1}) List<num> Ticks
Returns an list containing an arithmetic progression, similar to the Python built-in range.
tickIncrement(num start, num stop, num count) num Ticks
Like tickStep, except requires that start is always less than or equal to stop, and if the tick step for the given start, stop and count would be less than one, returns the negative inverse tick step instead.
ticks(num start, num stop, num count) List<num> Ticks
Returns an list of approximately count + 1 uniformly-spaced, nicely-rounded values between start and stop (inclusive).
tickStep(num start, num stop, num count) num Ticks
Returns the difference between adjacent tick values if the same arguments were passed to ticks: a nicely-rounded value that is a power of ten multiplied by 1, 2 or 5.