rank_eq
Rank of a value (ties get the same rank).
Syntax
Section titled “Syntax”v = rank_eq(number, ref, order)Description
Section titled “Description”Returns the rank of number among the values in ref. With order = 0 (default), ranks descending (highest = 1); with order = 1, ascending. Tied values get the same rank, with subsequent ranks skipping the appropriate count.
Example
Section titled “Example”rank_eq(7, [3 5 7 7 9]) % 2