Returns the name of a field that represents a category in data for the chart. It is needed to set up the amCharts Category axis.
amcharts.getCategoryName() has the following parameter:
rawData– Object. Raw data that contains the category (check out the structure of
Returns a string, which is the name of a field representing a category in the chart’s data.
Here is an example of setting the name for the amCharts Category axis:
var categoryAxis = chart.xAxes.push(new am4charts.CategoryAxis());
categoryAxis.dataFields.category = pivot.amcharts.getCategoryName(rawData);