Interchange axes and swap values axes appropriately.
previous
pandas.DataFrame.sum
next
pandas.DataFrame.swaplevel