<div dir="ltr"><div><div><div>If you know the artists you'd like to fire pick events for, you can work around it in a few different ways.  One option is to bind to mouse events and handle firing off pick events in that callback.<br><br></div>Here's how mpldatacursor gets around the twinx/twiny issue: <a href="https://github.com/joferkington/mpldatacursor/blob/master/mpldatacursor/datacursor.py#L658">https://github.com/joferkington/mpldatacursor/blob/master/mpldatacursor/datacursor.py#L658</a><br><br></div>Cheers,<br></div>-Joe<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Jan 31, 2018 at 1:31 AM, V. Armando Solé <span dir="ltr"><<a href="mailto:sole@esrf.fr" target="_blank">sole@esrf.fr</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On 30/01/2018 17:27, Benjamin Root wrote:<br>
> I seem to recall someone once messing around with the zorder of the<br>
> axes object, but I forget if that actually worked. Of course the other<br>
> workaround is to make the axes with the pickable objects be the twined<br>
> axes.<br>
><br>
<br>
</span>I'm using something on those lines since some time that works for me<br>
since quite some time. Here is a code fragment:<br>
<br>
            <a href="http://self.ax" rel="noreferrer" target="_blank">self.ax</a> = self.fig.add_axes([.15, .15, .75, .75], label="left")<br>
            self.ax2 = self.ax.twinx()<br>
            self.ax2.set_label("right")<br>
            # critical for picking!!!!<br>
            self.ax2.set_zorder(0)<br>
            self.ax2.set_autoscaley_on(<wbr>True)<br>
            self.ax.set_zorder(1)<br>
            self.fig.sca(<a href="http://self.ax" rel="noreferrer" target="_blank">self.ax</a>)<br>
<br>
Best regards,<br>
<br>
Armando<br>
<div class="HOEnZb"><div class="h5"><br>
______________________________<wbr>_________________<br>
Matplotlib-users mailing list<br>
<a href="mailto:Matplotlib-users@python.org">Matplotlib-users@python.org</a><br>
<a href="https://mail.python.org/mailman/listinfo/matplotlib-users" rel="noreferrer" target="_blank">https://mail.python.org/<wbr>mailman/listinfo/matplotlib-<wbr>users</a><br>
</div></div></blockquote></div><br></div>