Improve highcharts performance for large amounts of data

前端 未结 7 1319
名媛妹妹
名媛妹妹 2021-02-02 01:38

I am trying to get a larger amount of data. Sample data is below

1850/01   -0.845   -0.922   -0.748   -1.038   -0.652   -1.379   -0.311   -1.053   -0.636   -1.41         


        
7条回答
  •  南旧
    南旧 (楼主)
    2021-02-02 01:56

    I'd use underscore.js.

     var result = _.map(lines, function (row) {
        return { type: 'line', series: _.map(row.data, function (item, index) {
          if (index >= 1)
            return parseFloat(item);
        }), name: row.data[0]}
      });
    

    (I'm writing this from my phone on a plane, so my apologies if there is are any typos or things I'm missing. Just trying to help!)

提交回复
热议问题