• the reference percentrank: the percentage of the previous period values that are less than or equal to the current one. The current bar is the subject of the comparison, not part of the window, so the first answer lands at index period.

    Parameters

    • values: readonly number[]
    • period: number

    Returns number[]