Re: [Matplotlib-users] Pick event

2012-05-12 Thread Arek Kedzior
What I am trying is to plot multiple discontinuous lines. I know that this approach does not work very well.  How about using LineCollection. Put all curves into line collection Use Pick event to get line segment (what function to use ?) Once I have line segment, get xdata, ydata corresponding to l

Re: [Matplotlib-users] pick event

2012-05-12 Thread Jerzy Karczmarczuk
Arek Ke;dzior: If you pick one of the curves in the close location to tangancy area, the OnPick function will be executed twice (2 curves) and will display 2 markers. I want to find the shortest distance from the pick location (mouse coord.) to a discrete point on the curve and draw marker on t

Re: [Matplotlib-users] pick event

2012-05-12 Thread Arek Kedzior
If you pick one of the curves in the close location to tangancy area, the OnPick function will be ececuted twice (2 curves) and will display 2 markers. I want to find the shortest distance from the pick location (mouse coord.) to a discrete point on the curve and draw marker on the curve at this

Re: [Matplotlib-users] Matplotlib-users Digest, Vol 72, Issue 10

2012-05-12 Thread Arek Kedzior
If you pick one of the curves in the close location to tangancy area, the OnPick function will be ececuted twice (2 curves) and will display 2 markers. I want to find the shortest distance from the pick location (mouse coord.) to a discrete point on the curve and draw marker on the curve at this

Re: [Matplotlib-users] pick event

2012-05-12 Thread Benjamin Root
On Saturday, May 12, 2012, Jerzy Karczmarczuk wrote: > Arek Kędzior: > > I am trying to use pick event. > > ... > > What am I doing wrong ? > > Wrong with WHAT? > What do you expect? > > Jerzy Karczmarczuk > Arek. Could you provide a little more detail about your issue? Cheers! Ben Root -

Re: [Matplotlib-users] pick event

2012-05-12 Thread Jerzy Karczmarczuk
Arek Ke;dzior: I am trying to use pick event. ... What am I doing wrong ? Wrong with WHAT? What do you expect? Jerzy Karczmarczuk -- Live Security Virtual Conference Exclusive live event will cover all the ways today

[Matplotlib-users] pick event

2012-05-12 Thread Arek Kedzior
I am trying to use pick event.  See the simple script below.  I am interested to find the shortest distance between pick point (mouse coord.) and the  line at the discrete points only (points on the curve from data) What am I doing wrong ? Regards, Arek   import numpy as np import matplotlib.pyplot