Highcharts.chart('container', {
chart: {
type: 'area'
},
plotOptions: {
series: {
connectNulls: false,
// stacking: 'normal'
}
},
series: [{
fillOpacity: 0.75,
data: [
{ x: 0, y: 29.9 },
{ x: 1, y: 71.5 },
{ x: 3, y: null },
{ x: 4.3, y: 129.2, color: 'red' },
{ x: null, y: null },
{ x: null, y: null },
{ x: 8, y: 216.0, color: 'yellow' },
{ x: 9, y: 135.6, color: 'purple' },
{ x: 7.2, y: 148.5, color: 'lime' },
{ x: 12, y: 216.4 },
{ x: 14, y: 194.1 }
]
}]
});
<script src="https://code.highcharts.com/highcharts.js"></script>
<div id="container"></div>
I have troubles plotting the Highcharts area charts having non-monotonic data.
In given example, I would like to see:
- the red area filled with blue color as well
- the black-striped area possibly suggesting overlapping of multiple blue areas (using opacity or somewhat similar approach)
It looks like the Highcharts are using even-odd filling rule or something similar, but I cannot determine or find something about it in the manual.