get_subax¶
-
hhpy.plotting.
get_subax
(ax: Union[matplotlib.axes._axes.Axes, numpy.ndarray], row: int = None, col: int = None, rows_prio: bool = True) → matplotlib.axes._axes.Axes[source]¶ shorthand to get around the fact that ax can be a 1D array or a 2D array (for subplots that can be 1x1,1xn,nx1)
Parameters: - ax – The matplotlib.pyplot.Axes object to plot on, defaults to current axis [optional]
- row – Row index [optional]
- col – Column index [optional]
- rows_prio – decides if to use row or col in case of a 1xn / nx1 shape (False means cols get priority)
Returns: The matplotlib.pyplot.Axes object with the plot on it