My goal is to incorporate multiple series into my graph using data from a JSON file containing 4 columns (date, open incidents, closed incidents, and in progress incidents). I have successfully displayed the number of open incidents on my graph (http://jsfiddle.net/269us/), but I am struggling to access the 3rd and 4th columns of the JSON file.
This is the format of my JSON file:
[[1325462400000,3,12,14]
[1325548800000,7,14,8]
[1325635200000,10,11,24]
[1325721600000,21,13,16]
[1325808000000,13,15,9]
[1325894400000,2,15,4]
[1326067200000,10,13,15]]
I aim to achieve the following structure to customize each series (open, closed, in progress):
var date = []
open = []
close = []
inprogress = []
datalength = data.length;
for (i = 0; i <dataLength; i + +) {
date.push ([
data [i] [0]
]);
open.push ([
data [i] [1],
]);
close.push ([
data [i] [2],
]);
inprogress.push ([
data [i] [3],
]);
}
series: [{
type: 'spline',
name: 'open',
data: open,
dataGrouping {
units: groupingUnits
}
} {
type: 'column',
name: 'close',
data: close,
dataGrouping {
units: groupingUnits
}
.............
.............
}]