I have a seaborn barplot and a regression line graphed on top of it that looks like this. As you can see, I have a legend that is automatically created with seaborn.barplot() and I am attempting to add the R^2 score with this:
g = sns.barplot(x='City/Town', y="Value", hue="Metric", data=df, ax=ax1)
h, l = g.get_legend_handles_labels()
g.legend(h + [lin_reg.score(X, Y)], l + ['R^2 score'], title="Legend")
It doesn't throw an error, in fact I know it's working because it changes the title to "Legend", but it also doesn't add the R^2.
