For the legend to be picked by mouse, it must be placed in the top most axes.
ax = subplot(111)
l1, = ax.plot([1,3,2])
ax2 = ax.twinx()
lab = ax2.legend([l1], [test])
I hope this clarifies your issue.
If not, please post a simple but complete example that demonstrates
your problem.
Regards,
Yeap, that did the trick.
Thanks.
--
View this message in context:
http://old.nabble.com/legend-not-draggable-when-secondary-y-axis-present-tp33163397p33266687.html
Sent from the matplotlib - users mailing list archive at Nabble.com.
Any ideas?
Also, as in the example
herehttp://matplotlib.sourceforge.net/examples/pylab_examples/multiple_yaxis_with_spines.html,
the legend seems to be behind the quantity being plotted against the one of
the secondary y-axisdoes this have anything to do with that?...it is
that maybe the
Any ideas?
Also, as in the example
http://matplotlib.sourceforge.net/examples/pylab_examples/multiple_yaxis_with_spines.html
here , the legend seems to be behind the quantity being plotted against the
one of the secondary y-axisdoes this have anything to do with that?...it
is that maybe the