gpt4 book ai didi

python - Matplotlib 错误栏不以标记为中心

转载 作者:太空宇宙 更新时间:2023-11-03 11:51:40 24 4
gpt4 key购买 nike

在使用 errorbar 时,有什么技巧可以使错误栏居中于标记?

import matplotlib.pyplot as plt
plt.errorbar([1],[1],[0.1],fmt='k^',capsize=5,capthick=2,ms=9,markerfacecolor='none',mew=2)
plt.show()

在尝试制作带有错误栏的演示质量图时,这非常烦人。我所有的错误栏似乎都偏离中心一两个像素。这也会影响图例。我尝试了各种标记大小和线宽,但它们从未正确居中。在 Mac OX 10.8.4 上使用 matplotlib 1.2.1。在 mpl 1.3.1 上试过,得到了相同的结果。

Errobar bar obviously not in the center of the marker enter image description here

最佳答案

确认错误。 Github 问题已创建,并标记为在 MPL 1.4.x 中修复

关于python - Matplotlib 错误栏不以标记为中心,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/25451871/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com