Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

changing plot background color in python

### How to change plot background color

fig, ax = plt.subplots()
## to change the inside of the graph
ax.set_facecolor('xkcd:salmon')
ax.set_facecolor((1.0, 0.47, 0.42))
## to change the border color around the back
fig.patch.set_facecolor('xkcd:mint green')
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #changing #plot #background #color #python
ADD COMMENT
Topic
Name
6+8 =