Skip to content

charton API


charton API / @chart-on/core / index / priceTicks

Function: priceTicks() ​

priceTicks(min, max, heightPx, minSpacingPx?, alignStep?): PriceTicks

Defined in: packages/core/src/util/format.ts:36

Evenly spaced axis prices in [min, max], at least minSpacingPx apart. alignStep can widen the step, e.g. to land on a price format's ticks.

Parameters ​

min ​

number

max ​

number

heightPx ​

number

minSpacingPx? ​

number = 40

alignStep? ​

(step) => number

Returns ​

PriceTicks