I would like to add two (or more) axes (ax1
and ax2
in my example), coming from different parts of my program, to a unique raw Figure
.
Thus, in the first part of my program, I would do:
fig1, ax1 = plt.subplots(1, 1)
ax1.scatter(...)
ax1.imshow()
...
and in a second part of this same program:
fig2, ax2 = plt.subplots(1, 1)
ax2.plot(...)
...
I then would like to build a figure to incorporate these two axes ax1
and ax2
, with something like:
fig = plt.figure()
fig.add_my_subplots(ax1, ax2)