I'm trying to save a plot with the labels area (the area where you print the xlabel, ylabel and title) transparent and the main plot (the area where you plot the data) not transparent.
I'm using the transparent command in savefig:
plt.savefig("name",tranparent=True)
The problem is that this makes all the figure transparent.
In the documentation says this about the transparent argument:
transparent : bool
If True, the axes patches will all be transparent; the figure patch will also be transparent unless facecolor and/or edgecolor are specified via kwargs. This is useful, for example, for displaying a plot on top of a colored background on a web page. The transparency of these patches will be restored to their original values upon exit of this function.
So I tried changing the facecolor
and edgecolor
arguments, but I can't find a combination that gives the plot that I want.
Help.