I have the following array : (3,2,3,4,7,2,4,7)* which I need to renumber to : (1,0,1,2,3,0,2,3)
ie : the lowest value should become 0, the second lowest should become 1, etc.
The similar posts I could find have only one instance of each number, and the related answers cannot apply here because the repeated numbers should have the same renumber value.
Thank you
- the actual array has thousands of numbers.