pisces.geometry.grids.core.GenericGrid.get_axis_coordinate_array#

GenericGrid.get_axis_coordinate_array(axis: int | str, slc: slice) unyt_array#

Return the coordinate values along a single axis for a given slice.

Parameters:
  • axis (int or str) – The index or name of the axis to extract coordinates for.

  • slc (slice) – A slice object specifying the indices along the axis to extract.

Returns:

1D array of coordinate values for the selected slice along the axis.

Return type:

unyt.array.unyt_array