您在pylab.arrow
(或FancyArrow
)之后,然后您可以指定head_width
,head_length
因此它们与箭头的大小无关。这是一个例子:
import math
import pylab
pylab.plot(range(11), range(11))
opt = {'head_width': 0.4, 'head_length': 0.4, 'width': 0.2,
'length_includes_head': True}
for i in xrange(1, 360, 20):
x = math.radians(i)*math.cos(math.radians(i))
y = math.radians(i)*math.sin(math.radians(i))
# Here is your method.
arr = pylab.Arrow(4, 6, x, y, fc='r', alpha=0.3)
pylab.gca().add_patch(arr)
# Here is the proposed method.
pylab.arrow(4, 6, x, y, alpha=0.8, **opt)
pylab.show()
产生: