I usually draw plots using gnuplot. See Plot a spiral with gnuplot for an educational example.
Most interactive terminals (rendering frontend drivers) of gnuplot support using the mouse. These include the wxt and x11 terminals.
If you make a plot on such a terminal, then hover the mouse over the plot window, the coordinates of the hovered points will show up printed in the corner of the plot window. If you click the mouse, gnuplot stores the coordinates in the variables MOUSE_X and MOUSE_Y, which you can query with the print statement of gnuplot. I believe you can even bind a callback function gnuplot will execute on mouse clicks, see the gnuplot manual for details.
There is one limitation of mouse handling that is worth noting. If you are using a multiplot (multiple independent plot areas side by side in a window), then you can get the coordinates corresponding to the last plot area only.
In reply to Re: Hover over scatter plot
by ambrus
in thread Hover over scatter plot
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |