define
subplot(nrows, ncols, plot_number)
!note:
plot_number starts at 1, increments across rows first and has a maximum of nrows * ncols.
test
- code
import matplotlib.pyplot as plt
plt.figure(1)
plt.subplot(2,2,2)
plt.subplot(2,2,3)
plt.figure(2)
plt.subplot(2,1,1)
plt.subplot(2,1,2)
plt.show()
- result