Only this week, get the SQL Complete Track of 9 courses in a special prize of $330 $89!
What DataFrames are
DataFrame columns
DataFrame rows
Filtering rows and columns
Filtering data frames
Sorting rows
28. Sorting rows


Great! By default, rows are stored in the order given in the CSV file. Luckily, sorting rows in a DataFrame is a piece of cake. Take a look:

hospitals = hospitals.sort_values(by='Hospital overall rating')

The code above will sort the rows in hospitals in ascending order by the Hospital overall rating column values.


Which country has the smallest area in the EU? Sort the rows in eu_states by the Area column.

Stuck? Here's a hint!

Take a look at the example in the explanation and write a similar line of code.