This sample displays different aromas and tastes of coffee using colors.
Noteworthy things in the code:
- the 'ordinal-from-root' calculation method is selected;
- the labels are positioned radially in the penultimate level;
- the leaves use the minimum font size;
- the color of each subsequent level is defined by 'darken' function
that makes the color of the current level 15% darker than the parent color.
of different aromas and tastes of coffee taken as data. To create it, we applied the
‘ordinal-from-root’ method available in the AnyChart JS charting library.
Labels in the present HTML5 Sunburst Chart are positioned radially,
in the penultimate level, and the leaves feature the minimum font size.
Note that the color of each subsequent level is defined by the ‘darken’ function,
making the color of the current level 15% darker than the parent color.