【发布时间】:2020-10-12 01:50:33
【问题描述】:
我正在关注 Matplotlib 关于补丁的 this 教程。我了解它是如何工作的,但我唯一不明白的是如何为补丁设置颜色。假设我希望它们都是橙色的,我尝试了这个(来自代码):
for x1, y1, r, t1, t2 in zip(x, y, radii, theta1, theta2):
wedge = Wedge((x1, y1), r, t1, t2, color='orange')
patches.append(wedge)
但它没有为补丁设置颜色。我该怎么做?
【问题讨论】:
-
@JohanC 代码与我链接的示例完全相同;我只想自己设置颜色,但其余代码相同
标签: python matplotlib