I am trying to sort this dataframe, on abs(C)
A B C
0 10.3 11.3 -0.72
1 16.2 10.9 -0.84
2 18.1 15.2 0.64
3 12.2 11.3 0.31
4 17.2 12.2 -0.75
5 11.6 15.4 -0.08
6 16.0 10.4 0.05
7 18.8 14.7 -0.61
8 12.6 16.3 0.85
9 11.6 10.8 0.93
To do that, I have to append a new column D = abs(C), and then sort on D
df['D']= abs (df['C'])
df.sort_values(by=['D'])
Is there a way to do the job in one method?