On Fri, Oct 28, 2011 at 6:31 AM, Paul Hilscher <pphilscher...@gmail.com> wrote:
> Dear all,
> first of all thank you for the this awesome plotting library :D.
> I have a logarithmic plot where I want to stress out a specific range using
> a line like
> y    Something
> |   |-------------------|
> |   ___________
> |  /                   \
> | /                     \
> |/
> |--------------------------->
>           x
> I looked up the documentation but could find a proper arrow style or
> similar.
> Does anybody know how to do this the proper way ?
> I did that "manualy" using 3 plot commands and text() , but I guess there
> should be some nicer way ??

You can create the arrow with
   a = mpl.patches.FancyArrowPatch(posA=(4,4), posB=(7,4), arrowstyle="|-|")
   ax.add_patch(a)

or

   ax.annotate("", xy=(4,4), xytext=(7,4), arrowprops=dict(arrowstyle='|-|'))

and then adding your label manually with text(), like you said. There
may be some way to do it all in the annotate command (by shifting the
arrow away from the label somehow), but by default the annotate()
command draws an arrow from point xytext to xy (the point you're
labeling).

    Justin

------------------------------------------------------------------------------
The demand for IT networking professionals continues to grow, and the
demand for specialized networking skills is growing even more rapidly.
Take a complimentary Learning@Cisco Self-Assessment and learn 
about Cisco certifications, training, and career opportunities. 
http://p.sf.net/sfu/cisco-dev2dev
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users

Reply via email to