Required library edition:
Required library file: dhtmlxchart.js
The method groups data by a certain property. The method get an object with the following properties as a parameter:
Properties of grouped objects set in “map” are defined by an array. The first element of this array is a template with a property from original data, the second one – the functor which needs being applied to all values of this property in a group: “sum”, “max”, “min” or custom function
chart.group({ by:"#company#", map:{ sales:["#sales#","sum"] } });