Closed
Description
Trying to create filled plots with no lines, I used fill
with mode = 'none'
. This caused unexpected behavior of the first fill not showing up.
var data = [
{
"x": [1, 2, 3],
"y": [-2.0, -3.0, -4.0],
'type': 'scatter',
'mode': "none",
'showlegend': false,
"name": "1"
},
{
"x": [1, 2, 3],
"y": [-1.0, -2.0, -3.0],
'type': 'scatter',
'showlegend': false,
'mode': "none",
"name": "2",
"fill": "tonexty",
"fillcolor": "blue"
},
{
"x": [1, 2, 3],
"y": [0.0, 0.0, 1.0],
'type': 'scatter',
'showlegend': false,
'mode': "none",
"name": "3",
"fill": "tonexty",
"fillcolor": "green"
}
];
Plotly.newPlot(
"test", // the ID of the div
data, {});
The minimum moving example is here
This is the expected plots:
This can be achieved by passing 0 width line.
'mode': "lines",
'line': {'width': 0, 'color': 'green'},
I believe this is not a desired behavior?
It will be great if you can fix the problem or at least document it for fill
.