📜  matplotlib 显示两个不同的图 - Python 代码示例

📅  最后修改于: 2022-03-11 14:45:29.839000             🧑  作者: Mango

代码示例1
# credit to the Stack Overflow user in the source link
import matplotlib.pytplot as plt

fig1 = plt.figure(1)
""" generate your first plot (plt.hist, plt.plot etc.) """
fig1.show()

fig2 = plt.figure(2)
""" generate your second plot """
fig1.show()

input() # to keep both figures and choose them on the fly (in Python 3)