cf.Data.expand_partition_dims

Data.expand_partition_dims(pdim)[source]

Expand the shape of the partition matrix in place.

Insert a new size partition matrix dimension at position 0. The new dimension must be a dimension of the data array.

Not to be confused with the expand_dims method.

Parameters :
axis : str

The name of the new partition dimension.

Returns :

None

Examples

>>> d.pmdimensions
['dim0', 'dim1']
>>> d.expand_partition_dims('dim2')
>>> d.pmdimensions
['dim2', 'dim0', 'dim1']

Previous topic

cf.Data.conform_args

Next topic

cf.Data.new_dimension_identifier

This Page