I am working on Google charts API and Google Visualization Candlestick Charts expects data to be an array of arrays for it to work .
From back end i am reciving data in this format
[
{
"current_day":"2011-08-01",
"open_val":136.65,
"high_val":136.96,
"low_val":134.15,
"close_val":134.15
},
{
"current_day":"2011-08-02",
"open_val":135.26,
"high_val":135.95,
"low_val":131.50,
"close_val":131.85
}
]
Could you please tell me how can i construct this data to the below format
[
[ "2011-08-01", 136.65, 136.96, 134.15, 136.49 ],
[ "2011-08-02", 135.26, 135.95, 131.50, 131.85 ]
]
to feed it to Candlestick input format data in google charts .
my fiddle