I am new to PyQtGraph and want to use it for a speedy visualization of my data acquisition. Previously I was using matplotlib where redrawing the figure was my bottleneck. A
You need to setup a pyqtgraph.SignalProxy
and connect it to a callback:
if p
is your plot, it'll look like: pyqtgraph.SignalProxy(p.scene().sigMouseMoved, rateLimit=60, slot=callback)
Whenever the mouse is moved over the plot, the callback is called with an event
as an argument, i.e. callback(event)
. event[0]
holds a positional argument you pass to p.vb.mapSceneToView(position).x()
for x value and p.vb.mapSceneToView(position).y()
for y value.