question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Hover info broken in 3D scatter plot with opacity 1

See original GitHub issue

Hi, in 3D scatter when marker opacity is set to 1 and when you hover over any point only one hover label is shown. Specifically it is the label belonging to the first point in data. See for yourself:

x, y, z = np.random.multivariate_normal(np.array([0,0,0]), np.eye(3), 200).transpose()
trace1 = go.Scatter3d(
    x=x,
    y=y,
    z=z,
    mode='markers',
    marker=dict(
        size=12,
        line=dict(
            color='rgba(217, 217, 217, 0.14)',
            width=0.5
        ),
        opacity=1
    )
)

data = [trace1]
layout = go.Layout(
    margin=dict(
        l=0,
        r=0,
        b=0,
        t=0
    )
)
fig = go.Figure(data=data, layout=layout)
plotly.offline.iplot(fig)

scatter plot

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:17 (8 by maintainers)

github_iconTop GitHub Comments

1reaction
michalkahlecommented, Mar 11, 2019

Thank you @archmoj ! I can confirm the issue is gone in plotly for python v. 3.5.0 on Ubuntu.

1reaction
michalkahlecommented, Mar 14, 2018

I fixed this provisionally by adding this fake trace to the beginning of the list: go.Scatter3d(x=[0], y=[0], z=[0], marker={'color':'rgb(0, 0, 0)', 'opacity': 1, 'size': 0.1}, showlegend=False).

Read more comments on GitHub >

github_iconTop Results From Across the Web

Hover only works in one point in plotly's Scatter3D
Solved. I was setting opacity=1 and apparently you can't do that with 3D scatter plots when you set the line property. trace =...
Read more >
Completely excluding a trace from hover info/snapping
Hi, I have a scenario where my figure contains a mesh3d with scatter3d on top of it. Problem is that I only need...
Read more >
scatterD3 : a Visual Guide
Basic scatterplot; Global points settings; Tooltips; x and y axes ... point_opacity = 0.5, hover_size = 4, hover_opacity = 1).
Read more >
Hover Only Works In One Point In Plotly's Scatter3D - ADocLib
The data visualized as scatter point or lines in 3D dimension is set in x y z.Text appearing either on the chart or...
Read more >
Create 3D Scatter Plot -- Python Plotly - YouTube
Learn to create the 3D scatter plot in under 25 lines of code. We will also animate the plot, and save as html...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found