I made the plot above using seaborn but I am not able to place the legend outside plot properly. Please note that the legend is cut off on the right side of the image. This is how it looks in real, I did not cut it manually. This is the code I am using:
sns.lineplot(x="Time", y='Anomaly', style='country', hue='region', size='area', sizes=(1., 4), data=df)
# Put the legend out of the figure
plt.subplots_adjust(right=0.2)
plt.legend(bbox_to_anchor=(.95, 1), loc=2, borderaxespad=0.)
plt.tight_layout()
plt.show()
-- EDIT:
here is a data to replicate this issue: https://www.dropbox.com/s/w4gd447e22zb5yk/subset.csv?dl=0