coordax.CartesianProduct

class coordax.CartesianProduct(coordinates: tuple[Coordinate, ...])

Coordinate defined as the outer product of independent coordinates.

To construct a CartesianProduct, use coordax.coords.compose().

__init__(coordinates: tuple[Coordinate, ...]) None

Methods

__init__(coordinates)

from_xarray(dims, coords)

Construct a matching Coordax coordinate from xarray, if possible.

isel([indexers])

Returns a new coordinate with the given integer indexers applied.

map_indexers(indexers[, method])

Maps label-based indexers to integer-based indexers (indices/slices).

sel([indexers, method])

Returns a new coordinate with the given selection applied.

to_xarray()

Convert this coordinate into xarray variables.

Attributes

axes

Returns a tuple of Axis objects for each dimension.

dims

Dimension names of the coordinate.

fields

Returns a mapping from field names to their values.

ndim

Dimensionality of the coordinate.

shape

Returns the shape of the coordinate axes.

sizes

Sizes of all dimensions on this coordinate.