pandas.Series.argsort
pandas 3.1.1 · Series and accessors · method
Get positions describing the order that sorts the values.
Call syntax
Series.argsort(axis=0, kind='quicksort', order=None, stable=None)Run the example
Edit the example and select Run Python to see the result.
Parameters
| Parameter | Requirement | Accepted values and behavior |
|---|---|---|
axis |
Optional Positional or keyword Default 0 |
{0 or 'index'} Choose which axis the operation acts on. The accepted axis labels depend on the receiver. |
kind |
Optional Positional or keyword Default 'quicksort' |
{'mergesort', 'quicksort', 'heapsort', 'stable'} Choose the implementation variant, such as a sort algorithm or a plot type. |
order |
Optional Positional or keyword Default None |
None Specify the order in which levels or values should appear. |
stable |
Optional Positional or keyword Default None |
None |
Returns
Series[np.intp]