matplotlib.axes
matplotlib.axes.Axes.get_legend_handles_labels
Axes.
get_legend_handles_labels
Return handles and labels for legend
ax.legend() is equivalent to
ax.legend()
h, l = ax.get_legend_handles_labels() ax.legend(h, l)
Legend guide¶