ax1 = fig.add_subplot(1, 2, 2)
myhist(ax0, 'blue')
myhist(ax1, 'green')
say_something(ax0, 'this is the blue plot')
say_something(ax1, 'this is the green plot')
plt.show()
Python with matplotlib - reusing drawing functions