cf.Field.insert_dim¶
-
Field.
insert_dim
(item, key=None, axis=None, copy=True, replace=True)[source]¶ Insert a dimension coordinate object into the domain in place.
See also
insert_aux
,insert_axis
,insert_measure
,insert_data
,insert_ref
Parameters: - item : cf.DimensionCoordinate or cf.Coordinate or cf.AuxiliaryCoordinate
The new dimension coordinate object. If it is not already a dimension coordinate object then it will be converted to one.
- axis : str, optional
The axis for the item. The axis is given by its domain identifier. By default the axis will be the same as the given by the key parameter.
- key : str, optional
The domain identifier for the item. By default a new, unique identifier will be generated.
- copy: bool, optional
If False then the item is not copied before insertion. By default it is copied.
- replace : bool, optional
If False then do not replace an existing dimension coordinate object of domain which has the same identifier. By default an existing dimension coordinate object with the same identifier is replaced with item.
Returns: - out :
The domain identifier for the inserted item.
Examples: >>>