Description
From the discussion that came up in #5985 - that PR proposed 4 contour plots - on a mixture of log and linear axes - that should look identical but didn't, until fixed in the PR. If we make the same plots as a smoothed heatmap, they look identical as far as the smoothing goes, but we lose the first row of bricks on each log axis because its far edge would be at a negative coordinate:
Also closer to what we already do with smoothed heatmaps (the same mock after
Plotly.restyle(gd,{'type':'heatmap', 'zsmooth':'best'})
- the four variants look slightly different but I think this is actually a symptom of some funny and potentially incorrect things we're doing with extending beyond the data values to make the outer edges of the heatmap bricks - we may want to adapt this for log axes too, especially as this results in us dropping the first row/column in this case!):
Can we do a better job of picking brick edges in this case?
The figure above would be:
{
"data": [
{
"x": [1,2,3,4,5],
"y": [1,2,3,4,5],
"z": [
[0 , 3.1250, 12.5000, 28.1250, 50.0000],
[3.1250, 6.2500, 15.6250, 31.2500, 53.1250],
[12.5000, 15.6250, 25.0000, 40.6250, 62.5000],
[28.1250, 31.2500, 40.6250, 56.2500, 78.1250],
[50.0000, 53.1250, 62.5000, 78.1250, 100.0000]
],
"zsmooth": "best",
"type": "heatmap"
},
{
"x": [1,10,100,1000,10000],
"y": [1,2,3,4,5],
"z": [
[0 , 3.1250, 12.5000, 28.1250, 50.0000],
[3.1250, 6.2500, 15.6250, 31.2500, 53.1250],
[12.5000, 15.6250, 25.0000, 40.6250, 62.5000],
[28.1250, 31.2500, 40.6250, 56.2500, 78.1250],
[50.0000, 53.1250, 62.5000, 78.1250, 100.0000]
],
"zsmooth": "best",
"type": "heatmap",
"showscale": false,
"xaxis": "x2"
},
{
"x": [1,2,3,4,5],
"y": [1,10,100,1000,10000],
"z": [
[0 , 3.1250, 12.5000, 28.1250, 50.0000],
[3.1250, 6.2500, 15.6250, 31.2500, 53.1250],
[12.5000, 15.6250, 25.0000, 40.6250, 62.5000],
[28.1250, 31.2500, 40.6250, 56.2500, 78.1250],
[50.0000, 53.1250, 62.5000, 78.1250, 100.0000]
],
"zsmooth": "best",
"type": "heatmap",
"showscale": false,
"yaxis": "y2"
},
{
"x": [1,10,100,1000,10000],
"y": [1,10,100,1000,10000],
"z": [
[0 , 3.1250, 12.5000, 28.1250, 50.0000],
[3.1250, 6.2500, 15.6250, 31.2500, 53.1250],
[12.5000, 15.6250, 25.0000, 40.6250, 62.5000],
[28.1250, 31.2500, 40.6250, 56.2500, 78.1250],
[50.0000, 53.1250, 62.5000, 78.1250, 100.0000]
],
"zsmooth": "best",
"type": "heatmap",
"showscale": false,
"xaxis": "x2",
"yaxis": "y2"
}
],
"layout": {
"xaxis": {"domain": [0, 0.45]},
"xaxis2": {"domain": [0.55, 1], "type": "log"},
"yaxis": {"domain": [0, 0.45]},
"yaxis2": {"domain": [0.55, 1], "type": "log"},
"margin": {"l": 50, "b": 50, "r": 110, "t": 10},
"width": 500,
"height": 400
}
}