A simple example, let's say I have this DataFrame:
raw = pd.DataFrame(np.array([
[1, 2, 5, 'User 1', 5],
[1, 2, 3, 'User 2', 3],
[1, 2, 2, 'User 3', 5],
[3, 2, 4, 'User 4', 7],
[3, 2, 3, 'User 5', 2],
[3, 1, 6, 'User 6', 5],
[2, 2, 6, 'User 7', 1],
[2, 2, 5, 'User 8', 4],
[2, 2, 3, 'User 9', 8],
]), columns=['a', 'b', 'c', 'd', 'e'])
and below that code:
raw.set_index(['a', 'b', 'c'], inplace=True)
raw.sort_index()
raw.head(9)
The output looks like that:
Instead of sorting it first by a, then by b, then by c. ( the whole row )
How could it be solved?
