alphapepttools.pl.add_legend_to_axes_from_patches

alphapepttools.pl.add_legend_to_axes_from_patches#

alphapepttools.pl.add_legend_to_axes_from_patches(ax, patches, **kwargs)#

Make a legend and directly add it to a matplotlib axes object.

Expects a list of named patches.

Parameters:
  • ax (plt.Axes) – Matplotlib axes object to add the legend to.

  • patches (list[mpl.patches.Patch]) – List of patches to use for the legend.

Return type:

None

Returns:

None