Quantcast
Channel: 🎛️ Dash - Plotly Community Forum
Viewing all articles
Browse latest Browse all 6271

Mouse coordinates

$
0
0

Is it possible to get the current x,y coordinates of the mouse anywhere on the graph. Not just when hovering over a plotted data point, but any location on the graph?

I am able to get the horizontal and vertical spikes drawn intersecting on the cursor location, but can’t figure out how to get the actual x,y values at the intersection.

layout = {
‘xaxis’:{
‘showspikes’:True,
‘spikemode’:‘across’,
‘spikesnap’:‘cursor’
},
‘yaxis’:{
‘showspikes’:True,
‘spikemode’:‘across’,
‘spikesnap’:‘cursor’,
},
‘hoverdistance’:0,
‘spikedistance’:-1
}

1 post - 1 participant

Read full topic


Viewing all articles
Browse latest Browse all 6271

Trending Articles