Given a list of values for charting like the below arrays
var arrays = [["A", [
[1391032800000, 20],
[1389826800000, 4],
[1389913200000, 4],
[1390086000000, 6]
]
]];
var dates = arrays[0][1].sort(function(x, y) { return x[0] - y[0]; });
var map = dates.map(function(dt) { return [new Date(dt[0]), dt[1]]; });
console.log(map);
The map contains:
I need to add additional Array(2) values into the map variable for all the days that are missing between Jan 16 and the end date of Jan 30.
What's the quickest way to fill the missing zero values (for each missing day) in the array.

arrays