The option groupBar allows to group the data in bar and columns chart. Please check this option in the API documentation:
and the included example addChart/sample_3.php
About customize major and minor units, it's supported in bar bar and line charts through majorUnit and minorUnit parameters (and also scalingMax and scalingMin).
To customize charts using parameters or styles not supported in the API method
we recommend to use the replaceChartData method available in Advanced and Premium licenses:
with the MultiMerge class: