My D3 chart is currently displaying data from the same HTML page. However, I need to switch to using an external JSON file for populating the chart with data generated from a form. When attempting to replace the current "hard coded" data with the d3.json function, the chart gets completely destroyed. Can anyone help me figure out where I am going wrong?
Current files:
<script>
// Existing code here...
</script>
I want to replace the current data with this external JSON file:
[
[
{
"key": "ING_SW_CB",
"value": "5"
},
{
"key": "SB_SW_CB",
"value": "5"
},
// Other data points...
]
]
Your assistance in getting this resolved quickly is greatly appreciated as I have a deadline to meet!