polars.DataFrame.set_sorted
-
Flag a column as sorted.
This can speed up future operations.
- Parameters:
-
- column
-
Column that is sorted
- descending
-
Whether the column is sorted in descending order.
- nulls_last
-
Whether the nulls are at the end.
Warning
This can lead to incorrect results if the data is NOT sorted!! Use with care!
DataFrame.set_sorted(
column: str,
*,
descending: bool = False,
nulls_last: bool = False,
) → DataFrame
© 2020 Ritchie Vink
© 2022 Polars contributors
Licensed under the MIT License.
https://docs.pola.rs/api/python/stable/reference/dataframe/api/polars.DataFrame.set_sorted.html