I need to plot a line on x axis when ever a new year starts. I’ve been trying to modify this code but i cant find a solution without “hard coding” the value on the plotLines. Thanks for the help.
xAxis: {
plotLines: [{
color: 'red',
width: 2,
value: Date.UTC(2010, 0, 1),
dashStyle: 'longdashdot'
}],
}
Just iterate over your chart data to create the needed year options array!