9951 explained code solutions for 126 technologies


python-matplotlibHow to put grid lines below chart


import matplotlib.pyplot as plt
plt.rc('axes', axisbelow=True)
plt.bar(['UA', 'UK', 'USA'], [10, 11, 12])
plt.grid()
plt.show()ctrl + c
import matplotlib.pyplot as plt

loads Matplotlib module to use plotting capabilities

plt.rc

configure chart object

axisbelow=True

put axes objects (including grid) below chart figures

.bar

will plot bar chart

.grid(

add and configure grid

.show()

render chart in a separate window