Pie Chart with negative values.
Hello team, I've tried to provide some negative values in the Pie chart. Which results in unexpected outcomes. Since pie chart is not applicable for negative values, maybe taking the absolute value before plotting the chart would resolve this issue I think. The following are the steps to reproduce the issue:
- Create a pie chart with PieChartBuilder.
- While adding series using addSeries() give in some negative values. Eg;: chart.addSeries("A",-100);
I've also attached the screen shot of the rendered chart with [100,-100,100] as the series.
Thanks and Kindly do the needful.

taking the absolute value before plotting the chart would resolve this issue
That's one way to address the problem. IMHO another and yet cleaner would be to throw an exception for invalid input.
yes, I think there's similar "sanity check" code in other chart types that checks the input and throws an exception when the input is invalid.