Search code examples
ag-charts

How to correct the label for ag-charts radial-bar with custom start and end angle?


I want to create a gauge chart based on ag-charts radial bar. By setting the start angle to 270 degrees and the end angle to 450, I can achieve what I want for the most part; however, the values do not correspond visually to the labels on the chart correctly.

For example, the "Max" grade is set to 100, and you can see in the image below that it appears to align with a value of 160 instead.

Link to codesandbox: https://codesandbox.io/p/sandbox/axis-angles-forked-r3nlrn?workspaceId=1befe70e-e812-4c31-92c2-054ddb2de9e7

radial bar chart example

I've tried various other settings based on the example and API docs provided here: https://www.ag-grid.com/charts/javascript/radial-bar-series/#axis-angles

It seems even in the example provided in the ag-grid docs has the same issue?


Solution

  • This bug was fixed in version 10.2.0 which was released this morning.

    This version also includes radial and linear gauges.