Hi Travis,
Thank you for your patience.
When we tried to fix the reported scenario, we came to know
that when we add 0.2 and 0.1, it gives 0.3000004. Refer the below link
StackOverflow link: https://stackoverflow.com/questions/588004/is-floating-point-math-broken
So, to overcome the reported issue, we can set the labelFormat
property in primaryYAxis as n1 and change the first label in the
y-axis as 0 using the text argument in axisLabelRender event in
Charts. We have created a simple Javascript application to demonstrate the
same. Please find the below stackblitz link for your sample reference and stack
overflow link for your reference.
Sample link: https://stackblitz.com/edit/7tydmz-n6ctgt?file=index.js
Code Snippet:
|
primaryYAxis: {
minimum: 0,
maximum: 0.5,
interval: 0.1,
lineStyle: { width: 0 },
labelFormat: 'n1',
},
axisLabelRender: function (args) {
if (args.text === '0.0' &&
args.axis.name == 'primaryYAxis') {
args.text = '0';
}
},
|
Screenshot:

Kindly, revert us if you have any concerns.
Regards,
Swetha