-
-
Notifications
You must be signed in to change notification settings - Fork 18.8k
Closed
Labels
API DesignAlgosNon-arithmetic algos: value_counts, factorize, sorting, isin, clip, shift, diffNon-arithmetic algos: value_counts, factorize, sorting, isin, clip, shift, diffEnhancementNeeds DiscussionRequires discussion from core team before further actionRequires discussion from core team before further action
Description
Is your feature request related to a problem?
I am using pandas for a ranking task. The default series.rank() method returns ranks that starts at 1 instead of 0. Thus breaking some unexpected stuff if assuming 0 indexed result, as is common in python.
Describe the solution you'd like
Series.rank() should return 0 indexed values.
API breaking implications
Breaking existing code that rely on 1-indexed ranks
Describe alternatives you've considered
Shifting the output by -1 is the obvious solution, but feels weird.
Metadata
Metadata
Assignees
Labels
API DesignAlgosNon-arithmetic algos: value_counts, factorize, sorting, isin, clip, shift, diffNon-arithmetic algos: value_counts, factorize, sorting, isin, clip, shift, diffEnhancementNeeds DiscussionRequires discussion from core team before further actionRequires discussion from core team before further action