legend_outside

hhpy.plotting.legend_outside(ax: matplotlib.axes._axes.Axes = None, width: float = 0.85, loc: str = 'right', legend_space: float = None, offset_x: float = 0, offset_y: float = 0, loc_warn: bool = True, **kwargs)[source]

draws a legend outside of the subplot

Parameters:
  • ax – The matplotlib.pyplot.Axes object to plot on, defaults to current axis [optional]
  • width – how far to shrink down the subplot if loc==’right’
  • loc – one of [‘right’,’bottom’], where to put the legend
  • legend_space – how far below the subplot to put the legend if loc==’bottom’
  • offset_x – x offset for the legend
  • offset_y – y offset for the legend
  • loc_warn – Whether to trigger a warning if legend loc is not recognized
  • kwargs – other keyword arguments passed to pyplot.legend
Returns:

None