update the chart