Speed up aiCharts library

Tips to speed up aiCharts component

  • While operating over large amount of data points, consider using ChartPointCollection.beginUpdate()/endUpdate() (xxx.setData methods always use them by default). This will guarantee that ChartArea will not update itself in between beginUpdate() to endUpdate() boundaries.
  • Try to reuse old instances of ChartPoints. It will save garbage collector from unnecessary cleanups.
  • If you know range that ChartAxis will have, consider setting it via ChartAxisScale.setRange()\setDateRange()\setMinimum()\setMaximum().
  • Turn on the hit testing only if you really need it.
  • Choose FastLine chart type over Line chart type if you are not planning to have labels for points.
↑ Go to top