polars.Series.argsort#

Series.argsort(descending: bool = False, nulls_last: bool = False) Series[source]#

Get the index values that would sort this Series.

Alias for Series.arg_sort().

Deprecated since version 0.16.5: Series.argsort will be removed in favour of Series.arg_sort.

Parameters:
descending

Sort in descending order.

nulls_last

Place null values last instead of first.