Quite a subjective question in reality, however I am just trying to explore some options to create a flare.json output for my D3js visualisations.
At the moment I have a JSON structure for D3js as follows:
{
"name": "Engage Stats",
"children":
[
{
"name": "Unique Requests by Device",
"children":
[
{"name": "Android", "size": 80},
{"name": "IOS", "size": 366}
]
},
{
"name": "Overall Requests by Device",
"children":
[
{"name": "Android", "size": 2645},
{"name": "IOS", "size": 11703}
]
},
.... etc etc
My data is being retrieved from MS-SQL using a stored proc. Obviously one way is to simply read through my dataset (I should have said I am using C#/.NET at the backend) and build up the JSON structure row by row.. however I just wonder if anyone else has had a better/cleaner idea!
I guess because I am using the flare.json format for more of the visualisations, I can create a library to do the heavy lifting - again, just interested in a other perspectives to achieve this.