plotomics
    Preparing search index...

    Function formatTick

    • A tick label with the decimals its step needs. percent prints a fraction as a percentage. Large values print as thousands ("k") or millions ("M") when the step is a whole number of them, so the label stays exact. A value of a million or more prints in millions whenever the step is a whole number of ten thousands, so "1.5M" never reads "1500k". unit sets the unit instead; formatTicks gives every tick of an axis the same one. A step of 0 marks the one tick of a flat range, which has no step: it prints the value itself, every digit of its whole part and up to six significant digits in all, in exponent form below 1e-6, so a small value never reads as 0 and a large one is never rounded. A value that is not a finite number prints "NA".

      Parameters

      • value: number
      • step: number
      • opts: { percent?: boolean; unit?: TickUnit } = {}

      Returns string