cf.Coordinate.squeeze¶
-
Coordinate.
squeeze
(axes=None, i=False)[source]¶ Remove size 1 dimensions from the data array and bounds in place.
New in version 2.0.
See also
Parameters: - axes : (sequence of) int, optional
The size 1 axes to remove. By default, all size 1 axes are removed. Size 1 axes for removal may be identified by the integer positions of dimensions in the data array.
- i:
bool
, optional If True then update the coordinate in place. By default a new coordinate is created. In either case, a coordinate is returned.
Returns: out : cf.Coordinate
Examples: >>> c.squeeze() >>> c.squeeze(1) >>> c.squeeze([1, 2])