Learn Before
Idea
Sorting in pandas
There are three sorting methods in pandas.
- By rows: pd.sort_index()
- By columns: pd.sort_index(axis = 1)
- By values: pd.sort_values(by = 'col')
To change the order, set "ascending = False"
0
1
Updated 2021-02-05
Tags
Data Science