用python的matplotlib绘图,如何使用fill_between函数,使折线图在直线40...答:用python的matplotlib绘图,如何使用fill_between函数,使折线图在直线40以上的填充为绿色? 5 说明:x,y是整形数组 plt.plot(x, y) axhline(40,linestyle='--',linewidth=2, color='red') plt.fill_between(x, y, 40, where=(y>=40), facecolor='green') 程序出错,错误是: Traceback (most recent ...