Best Answer · By JanBask Data Science Expert
Ranjana Admin JanBask Expert
Answered on Jan 15, 2020
For sorting and ordering a dataframe, we need to create a dataframe.
import pandas as pd
df=pd.DataFrame({'col2':[444,555,666,444],'col3':['abc','def','ghi','xyz']})
df.head()

Now we sort and order the dataframe
df.sort_values(by='col2')
