【发布时间】:2018-07-03 13:55:34
【问题描述】:
假设我同时有 2 个 Matplotlib 图形,它们在 for 循环中更新。其中一个数字(假设fig0 有图像,而fig1 是线图)。我希望fig0 在fig1 中具有标准的Matplotlib 样式我想为fig1 设置plt.style.use('ggplot')。
到目前为止,我已经尝试过:
plt.style.use('ggplot')
fig0 = plt.figure(0)
fig1 = plt.figure(1)
for i in range(10):
# print stuff in both figures
但这会在两个图中设置ggplot 样式(如预期的那样)。我找不到在每个图中单独设置样式的方法。
【问题讨论】:
标签: python matplotlib