AnyChart | How to create chart with multiple series...
Welcome, Guest Login

Support Center

How to create chart with multiple series using JSON format?

Last Updated: May 28, 2018 11:42PM MDT
JSON data set can contain one or several series - almost the same way you can do this in JavaScript. Setting data using JSON format is very similar to the way of setting data in JavaScript. The name of every object in JSON configuration corresponds to the name of a method or parameter in JavaScript. So to create, e.g. line series using JSON, you should use this code:

"seriesType": "line":
"series": [{
  //series type
  "seriesType": "line"
  //series data
  "data": [
    {"x": "P1", "value": "128.14"},
    {"x": "P2", "value": "112.61"},
    {"x": "P3", "value": "163.21"},
    {"x": "P4", "value": "229.98"},
    {"x": "P5", "value": "90.54"}

And here is a sample with multiple series.

Contact Us
seconds ago
a minute ago
minutes ago
an hour ago
hours ago
a day ago
days ago
Invalid characters found