amcharts4 icon indicating copy to clipboard operation
amcharts4 copied to clipboard

How to Plot the Chart in the Same Order of Data Given as Input ?

Open VineelaKantamneni opened this issue 1 year ago • 2 comments

Hi, I'm designing a stacked bar chart with two series originated and received. when chart is drawn I'm getting data plotted in reverse order.

Data given as Input : chart.data = [ { "Originated": 0, "Received": 19484.33, "name": "JK" }, { "Originated": 0, "Received": 16776.13, "name": "MN" }, { "Originated": 0, "Received": 35, "name": "VK" } ]

Output Chart : Screenshot from 2024-01-31 18-23-57

I want JK should be the first bar then MN then VK as in the order of input data given to the chart.

Can you please help me to fix this?

Thanks in advance

VineelaKantamneni avatar Jan 31 '24 13:01 VineelaKantamneni

Would you be able to post your whole chart and data on CodePen/jsFiddle so that we can test?

martynasma avatar Jan 31 '24 13:01 martynasma

Hi, categoryAxis.renderer.inversed = true;

I kept inversed as true that's why I got like above after removing that it's fine. Thank you for the response.

VineelaKantamneni avatar Feb 01 '24 10:02 VineelaKantamneni

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.

github-actions[bot] avatar Mar 03 '24 00:03 github-actions[bot]