Optimized algorithm of updating a flot chart.