hoverdistance broken in 3D scatter plots (hover radius vs click radius)?
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 18.3k
- Forks
- 2k
- Avg merge
- 2d 12h
- Merged PRs (30d)
- 28
Description
Hi,
I want to use plotly in interactive dashboards. With my 3D scatter plots, I noticed that it's quite confusing that the click radius is different from the hover radius: when you move the mouse inside a point's hover radius, you get the hover lines that point to the axes, but it doesn't react to clicks yet. For that, you have to go much closer.
Is there a way to change the click radius to match the hover radius?
So I tried to change the hoverdistance parameter in the layout object, but realized that it seems that hoverdistance is broken in 3D plots. Here's a working example. You will see, that changing the hoverdistance doesn't make any difference:
https://codepen.io/bolau/pen/LYvPmWw
Is this a bug, or am I doing something wrong?
Here's the link to the documentation on the hoverdistance parameter, which doesn't distinguish between 2D and 3D plots:
https://plotly.com/javascript/reference/layout/#layout-hoverdistance
Best, Boris
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the linked CodePen reproduction and the layout.hoverdistance documentation, then compare hover and click behavior in 3D scatter plots. Done means determining whether hoverdistance should control the reported 3D behavior, with the implementation or documentation reflecting the result and the click-radius question addressed.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- data-visualization
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100