When setting the transparency in a legend:
plt.legend(framealpha=0.5)
it affects both the background and the edge. How can I apply transparency only to the background and not to the edge?
I have tried:
plt.legend(edgecolor=(0, 0, 0, 1.), facecolor=(1, 1, 1, 0.1))
with which I can change the color but not the transparency, i.e., using facecolor=(1, 0, 0, 0.1) does change the background color to red but using facecolor=(1, 0, 0, 0.5) doesn't make any difference in transparency.
I'm using matplotlib v3.1.1.