Edit this page

series.aggregate String |Function (default: "max")

The aggregate function to apply for date series.

This function is used when a category (an year, month, etc.) contains two or more points. The function return value is displayed instead of the individual points.

The supported values are:

  • "avg" - the average of all values for the date period.
  • "count" - the number of values for the date period.
  • "max" - the highest value for the date period.
  • "min" - the lowest value for the date period.
  • "sum" - the sum of all values for the date period. Defaults to 0 if no data points are defined.
  • "sumOrNull" - the sum of all values for the date period. Defaults to null if no data points are defined.
  • "first" - the first value
  • function(values, series, dataItems, category) - user-defined aggregate function. Returns single value or data item.
  • object - (compound aggregate) Applicable to "candlestick", "boxPlot" and ohlc "series". Specifies the aggregate for each data item field.
Example - set the chart series aggregate
<div id="chart"></div>
<script>
$("#chart").kendoChart({
  categoryAxis: {
    categories: [
      new Date("2012/01/01"),
      new Date("2012/01/02"),
      new Date("2012/01/02")
    ],
    type: "date"
  },
  series: [{
      data: [1, 2, 3],
      aggregate: "avg"
  }]
});
</script>
Is this article helpful? Yes / No
Thank you for your feedback!

Give article feedback

Tell us how we can improve this article

close
Dummy