It's easier to show than to explain I think
I'm trying to do something like this:
Code: Select all
Highcharts.chart('container', {
xAxis: {
plotBands: [{
color: '#FCFFC5',
from: function() {
var MinDate = new Date(1539182943000);
return Date.UTC(MinDate.getFullYear(),MinDate.getMonth() ,MinDate.getDate() ,6,0,0);
},
to: function() {
var MinDate = new Date(1539182943000);
return Date.UTC(MinDate.getFullYear(),MinDate.getMonth() ,MinDate.getDate()+2 ,22,0,0);
},
}],
tickInterval: 24 * 3600 * 1000, // one day
type: 'datetime'
},
series: [{
data: [29.9, 71.5, 106.4, 129.2, 144.0, 176.0, 135.6, 148.5, 216.4],
pointStart: Date.UTC(2018, 9, 9),
pointInterval: 24 * 3600 * 1000
}]
});
I want to make plotbands based on a given unix timestamp.
How can I do this?