ndarray.transpose

ndarray.transpose(self, *axes)

Permute the dimensions of an array.