Pandas · Function
df.sort_values
Sort a DataFrame by one or more columns, or sort labels along an axis. You can control direction, missing values, index labels, and the values used for comparison.
Last updated
Syntax
DataFrame.sort_values(by, *, axis=0, ascending=True, inplace=<no_default>, kind='quicksort', na_position='last', ignore_index=False, key=None)In-depth API docs are only for subscribers: parameters, examples, common mistakes and interview practice.
SubscribeRelated
DataFrame.sort_indexSeries.sort_values