Matt H on 19 Sep 2019 08:58:49
I'd like a way for RANKX to arbitrarily/randomly break runs of tied data. An example set of 5 categories could see a ranking such as the following Blue - 1, Yellow - 2, Red - 3, Green - 3, Pink - 5 using the SKIP argument. I'd like, in this example, for either Red or Green to see a 4 as its rank. I don't care how it happens, just need it to be a series of rank values in certain use-cases, rather than grouping the ties.
- Comments (4)
RE: RANKX new tie-breaking argument (SKIP, DENSE exist now...) RANDBREAK
bump... RANKX() needs to support Tie Breaker.
RE: RANKX new tie-breaking argument (SKIP, DENSE exist now...) RANDBREAK
I've needed to break ties previously in a non-random way, and did it by having a CustomerID table with a numerical index that I then divided by a very large number, which leaves a very small number for each CustomerID. I then added that in my measure to whatever else I was measuring, which got rid of the tie breaks.
RE: RANKX new tie-breaking argument (SKIP, DENSE exist now...) RANDBREAK
This is particularly difficult to replicate in DAX currently, and would be a very useful (though admittedly potentially dangerous) third option. I like the name "Randbreak" too (better than "Unique" , "Tiebreak", etc)
RE: RANKX new tie-breaking argument (SKIP, DENSE exist now...) RANDBREAK
Thanks Steve! I agree, to achieve desired results your data needs either a unique ID field or a date field which you know will be unique in any filter context.
Hope they can add it!