ensure_axes_array#

ensure_axes_array(axes: Axes | np.ndarray[Any, Axes] | UnsetType = Unset, axis: UnsetType = Unset) np.ndarray[Any, Axes][source]#

Ensure that axes have flatten method even if it is a single axis.

Parameters:
  • axes (Axes | np.ndarray[Any, Axes] | UnsetType) – Axes or array of Axes to convert for API consistency.

  • axis (UnsetType) – Deprecated use axes instead. Defaults to Unset.

Returns:

Numpy ndarray of axes.

Return type:

np.ndarray[Any, Axes]

Raises:

ValueError – If axes was not provided, ax should be a required argument but to facilitate the deprecation axis -> axes it has a default of Unset.