I want to use some kind of callback function that will run some code once the C3 Graph is finished loading so that I can change the fill colors of certain points.
js is a JavaScript library for manipulating documents based on data. c3. js is a Javascript library which makes it easy to generate D3-based charts (less code to write). highchart is a Javascript charting framework.
This library is used to create a dynamic and interactive data visualizations. C3 is a library build on top of D3. C3 is d3 based reusable chart library and most important advantage of using c3 is that you don't have to know D3 or write those long codes!.
Don't load any data in the initialization. Rather explicitly call the load event and pass the data in. Then you have access to the done
callback.
var chart = c3.generate({ /*...*/ });
chart.load({
columns: [['data1, 100, 200, 150, ...],
...
],
done: function() { /* whatever you need done here... */}
});
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With