我有以下网格图,想画一个箭头(使用 MS 绘图显示为蓝色)。我怎样才能通过 matplotlib 做到这一点?我不知道执行此操作的任何命令。
最佳答案
import matplotlib.pyplot as plt
fg = plt.figure(1);
fg.clf();
ax = fg.add_subplot(1,1,1)
ax.annotate('', xy=(0, -0.1), xycoords='axes fraction', xytext=(1, -0.1),
arrowprops=dict(arrowstyle="<->", color='b'))
ax.grid(True)
fg.canvas.draw()
给出
关于python - 在 Matplotlib 绘图外绘制箭头,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/23922804/