I have the following matrix
a=np.array([[1,-2],[2,-3]])
and i want to obtain this one
[[2,-3],[1,-2]]
meaning i have sorted the matrix with respect to the 2nd column.
I have tried the following code that don't work
a=np.array([[1,-2],[2,-3]])
a.sort(axis=1)
print(a)
which give me
[[-2,1],[-3,2]]
Thank you for your answers