Home > front end >  Javascript: how to use an array to hightchart set for the same Series channel difference in differen
Javascript: how to use an array to hightchart set for the same Series channel difference in differen

Time:12-02

Will hightchart same Series channel differences in object form set into a different color can be used to form such as:
Data: [{x: * * * y: * * *, color: * * *}, {x: * * * y: * * *, color: * * *}]...
Form easily, but in order to solve in dealing with a large amount of data, data array elements are objects appear highcharts error highcharts. Js: 12 # 12, the problem of selecting the array elements in an array data type, in the following form:
Data: [[x, y], [x, y], [x, y]]...
Written as hightchart to set for the same Series channel difference in different color should be how to implement?

CodePudding user response:

The data using ajax request feel better

CodePudding user response:

No, don't understand what you said "highcharts error highcharts. Js: 12 # 12" and what is the relevance of change data form you...

If you are want to: data: [[x, y], [x, y], [x, y]]... Convert data: [{x: * * * y: * * *, color: * * *}, {x: * * * y: * * *, color: * * *}]...
The only need to traverse the data, and then assembled into object you want to go?
  • Related