plotomics
    Preparing search index...

    Function snapRatio

    • x as the whole number it is close to, else x. Close means within one part in a million of x, and never more than a thousandth. A ratio of a value to a step is snapped before it is rounded up or down, so float32 noise, such as 0.3 sent from Python as 0.30000001192092896, neither adds a step nor drops a tick.

      Parameters

      • x: number

      Returns number