I just want to draw a few vectors of different colors.
In Mathematica I would use Arrow:
http://reference.wolfram.com/mathematica/ref/Arrow.html

In Matplotlib I cannot find an easy way.  Here's the best
I came up with so far.

import matplotlib.pyplot as plt
from matplotlib.patches import Arrow
fig, ax = plt.subplots(1,1)
ax.set_aspect('equal')
ax.add_artist( Arrow(0,0,1,1, width=0.1, facecolor='red',edgecolor=None) )
ax.add_artist( Arrow(0,1,1,-1, width=0.01, facecolor='k',edgecolor=None) )

Things that seem wrong with the interface:
- takes 4 numbers instead of a list of points
- head length and width is not determined by the line width
- edge drawing cannot (?) be turned off

The head drawing issue is particularly serious.

So, have I overlooked an easy way to do what I want?

One other question: am I supposed to use `add_patch` or
`add_artist`, and why?

Thanks,
Alan Isaac

------------------------------------------------------------------------------
WatchGuard Dimension instantly turns raw network data into actionable 
security intelligence. It gives you real-time visual feedback on key
security issues and trends.  Skip the complicated setup - simply import
a virtual appliance and go from zero to informed in seconds.
http://pubads.g.doubleclick.net/gampad/clk?id=123612991&iu=/4140/ostg.clktrk
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users

Reply via email to