Figures

NOTE: MUST BE INSIDE OF THE SAME CELL

Basics

Create fig

fig = plt.figure()
# dpi=1000, dots per inch
# figsize=(12,8), size is (12, 8) inches

Adjust parameters

axes1 = fig.add_axes([0,0,1,1]) # x start, y start, x height, y height
axis1.plot(x, y) # plots on the graph axis
axis1.plot(c, d) # plots a new line on the same graph

# add a second plot
axes2 = fig.add_axes([0.5,0.5,0.5,0.5]) 
axis2.plot(a, b) 

Style

axes1.set_xlim(min, max)
axes1.setx_xlabel('x-axis')
axes1.set_title('plot')

Show

plt.show()

Export

fig.savefig('newFig.png', bbox_inches='tight')