Ok, I have exhausted all my google searches and have reached a point of I have no idea how to do that. It seems so simple, still, i have tried like 20 approaches and nothing works. I need help...
Using the following code i get this:
import matplotlib.pyplot as plt
plt.rcParams['axes.facecolor'] = "#F3F0E0"
plt.rcParams['figure.facecolor'] = "#F3F0E0"
plt.figure(figsize = (6,3))
plt.plot([1,3,2])
plt.show()
I would like to have something like this, with ample margins left and right. Would be also nice to have a simmilar aproach for top and bottom.
I have played around with tight_layout() and many other settings but I'm failing miserably to make it work.
An ugly hack would be to include:
plt.text(1.1, 1.1, "text", fontsize=14, transform=plt.gcf().transFigure)
plt.text(-.1, -.1, "text", fontsize=14, transform=plt.gcf().transFigure)
And then to make the text the same color as the background But of course i would like to have a more elegant way to do it
The idea is that a plot with some margins left and right looks more relaxed to the eye. Of course, I can fix this in other software but I would like to have it ready in plt.