Permute the axes of the data array in place.
Parameters : |
|
---|---|
Returns : | out : cf.Field |
See also
axes, expand_dims, flip, squeeze, swapaxes, unsqueeze
Examples
>>>f.items() {‘dim0’: <CF DimensionCoordinate: time(12) noleap>,
‘dim1’: <CF DimensionCoordinate: latitude(64) degrees_north>, ‘dim2’: <CF DimensionCoordinate: longitude(128) degrees_east>, ‘dim3’: <CF DimensionCoordinate: height(1) m>}
>>> f.data_axes()
['dim0', 'dim1', 'dim2']
>>> f.transpose()
>>> f.transpose(['latitude', 'time', 'longitude'])
>>> f.transpose([1, 0, 2])
>>> f.transpose((1, 'time', 'dim2'))