From the course: Code Clinic: JavaScript

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Charting basic data with C3.js

Charting basic data with C3.js - JavaScript Tutorial

From the course: Code Clinic: JavaScript

Start my 1-month free trial

Charting basic data with C3.js

- [Instructor] Although we could use a formula to calculate the coefficient, I think it's a lot more fun to visualize the data and it helps you see things that a simple number is not going to give you. So, I'm using this chart library called C3.js. It's a D3-based reusable chart library and you can find some courses on D3 in the library. It's super easy to use and it create really nice charts. There's a lot of examples in this example section, so you could see that you can create different types of charts and the one that we're interested in is going to be this Timeseries Chart. And it looks like this, and once you get into an example, you can sort of look at the code and can see that the way that I am passing along this data is the way that these columns are supposed to be specified. And I'm going to use this in our code, so let's get right to it. I'm gonna come in here and create a new function. So I'll put it right on top of this. And I'm gonna call this generate chart. It's going…

Contents