我想用matplotlib制作一个图形,其中图形中的错误条是垂直的,但图例中的错误条是水平的。示例代码(如下所示)生成了一个图形,其中图例中的错误条是垂直的。如何使图例错误条水平显示?代码:import matplotlib.pyplot as plt
x = np.linspace(0, 2*np.pi, 6)
我正在尝试运行Matplotlib中的演示代码: the 。当我点击图例上的线条时,事件'pick_event‘似乎没有被触发。# Enable picking on the legend to toggle the legended line on and offimport numpy as np
import matplotlib.pyplot