I have a scatter graph i have created in matplotlib
I also have a list of tuples like so, [(1,’A’ 2),(2,’B’,0),(0,’D’,3)]
that i need to relate to a certain plot on my graph.
say when you click the point it somes up with the certain points, or have them at the bottom of the graph, different coloured point relating to different sequence and when you click the certain coloured point it highlights point on the graph its related too
I was just wondering if either of these are possible using matplotlib, and if there are, are there any good websites to use or any specific way to go about this?
Thanks in advance
Use pick events.
A simple examle that adds annotations to a scatter plot when you click on the markers:
(this assumes you have started ipython with –pylab to get the imports right)
You can replace the code in
onpickwith code that does what ever you want (and remember closures exist).This is a nice set of demos.
Also see
mpldatacursor