I try to display line graphs to show trend of multiple categories over time horizon. Below is my code. But it can't display any graphs. Thus, I wonder if it's because the data structure is incorrect. Below are HTML and JavaScript for my situation. JSFiddle Onlie
HTML Script
<script src="http://code.highcharts.com/highcharts.js"></script>
<script src="http://code.highcharts.com/modules/data.js"></script>
<script src="https://rawgit.com/mholt/PapaParse/master/papaparse.js"></script>
<script src="https://code.highcharts.com/modules/exporting.js"></script>
<pre id="line_bl" style="display:none">Date,Installation,Manufacturing,Sales,Project Development,Other,
2017-06-26,0.25,7,0.5,2.25,null,
2017-07-03,null,6.5,2.4,2.65,0.7,
2017-07-10,null,6.3,3.4,3.65,0.65,
2017-07-17,0.75,6.25,2.25,2.75,0.5,
</pre>
<div id="trend_bl"></div>
JavaScript
Highcharts.chart('trend_bl', {
title: {
text: 'Trend by Business Lines'
},
yAxis: {
title: {
text: 'Resource Allocation'
}
},
legend: {
layout: 'vertical',
align: 'right',
verticalAlign: 'middle'
},
plotOptions: {
series: {
pointStart: 2010
}
},
data: {
line_bl: document.getElementById('line_bl').innerHTML
},
});
The result I want should look similar to below: Line Graph