How do I invert a dataframe?

Asked

Viewed 22 times

-1

Dataframe

How do I display this df in reverse order ? I did the inversion by the index, but only the index reversed, the data of the dates without inversion remained in the same position. Basically I want to display the df from bottom to top, in the reverse order of the image, so the graphics will come out the way I want.

  • 1

    Use the df.sort_index() or df.sort_index(ascending=False)

No answers

Browser other questions tagged

You are not signed in. Login or sign up in order to post.