Skip to content

Invalid heatmap values #2233

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
workerclass opened this issue Jan 4, 2018 · 10 comments · Fixed by #2288
Closed

Invalid heatmap values #2233

workerclass opened this issue Jan 4, 2018 · 10 comments · Fixed by #2288
Labels
bug something broken

Comments

@workerclass
Copy link

This heatmap shows that my values are (15, 22.75), (22.75, 28), (26, 11), the first two are wrong.

https://jsfiddle.net/zc5r6v6t/3/

plotly

@alexcjohnson alexcjohnson added the bug something broken label Jan 4, 2018
@alexcjohnson
Copy link
Collaborator

Yes, you're right - thanks! We don't handle nonuniform brick sizes correctly. We've labeled the center of the brick, but as the brick boundaries are drawn halfway between adjacent data values, the brick center is not the same as the data values that created the brick in the case of nonuniform bricks.

@alexcjohnson
Copy link
Collaborator

Actually the problem is deeper than just hover labels - consider what happens when you set zsmooth: 'best' in that same plot (that triggers automatic connectgaps) - you can see that the color is ascribed to the brick center as well, and not to the data point as desired.
screen shot 2018-01-04 at 2 16 52 pm
And it spills over into contour traces too: the contour lines themselves are fine, as are the hover labels, but coloring: 'heatmap' puts the colors in the wrong places again.
screen shot 2018-01-04 at 2 21 18 pm

@LarryMartell
Copy link

Any ETA on when this will be fixed?

@LarryMartell
Copy link

Looks like the same bug exist with a contour map as well.

@LarryMartell
Copy link

Does this mean it is fixed? How can I get the latest code with the fix?

@alexcjohnson
Copy link
Collaborator

v1.33.1 will be published later this afternoon including this fix. Until then you can build your own bundle from the master branch.

@LarryMartell
Copy link

That is great. I will wait for 1.33.1. Can you let me know when it's available for download?

@alexcjohnson
Copy link
Collaborator

We hit a snag actually publishing to npm and our CDN (may not happen until Monday), but if you just want the built files, these have been updated and you can download them from https://github.com/plotly/plotly.js/tree/master/dist

@LarryMartell
Copy link

I pulled the latest and it does seem to fix this bug in heatmaps. However it seems to have introduced a new bug. I have plots with a title in them and in the new version the title is not displayed. Here are 2 screen shots showning the plots with the old and new versions. The same code and data is used in both. I will try and put up some codepens tomorrow to demonstrate this, buy clearly the new version has broken something,
screen shot 2018-01-25 at 10 33 03 pm
screen shot 2018-01-25 at 10 32 21 pm

@alexcjohnson
Copy link
Collaborator

I pulled the latest and it does seem to fix this bug in heatmaps. However it seems to have introduced a new bug.

Yikes, that's no good! Please open a new issue though, as it does not look related to the heatmap issue, must have been introduced by something else that happened in the same release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug something broken
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants