Highcharts / Highstock step line with gaps?

2019-07-19 03:00发布

问题:

Is it possible to have a step line with gaps? I'm talking about the square wave kind of line (step line) that would have gaps?

This kind of line (at least in my case) is drawn from such a dataset that has the start time and the new value (level) as one data point. For example can I set NULL to be a level to achieve gaps in the line?

回答1:

Yes, it's possible. Just add null point when you need a gap. Just like this: http://jsfiddle.net/mCLpr/

    series: [{
        data: [1,2,3,4,null,6,7,null,9],
        step: 'right',
        name: 'Right'
    }]