We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I want to add a unit test in my application that allows me to verify that the data on the Piechart is being correctly displayed.
I would therefore need to get the name and percentage value of each slice. What is the simplest way to do it?
Currently I can only extract the name of the slice and not the percentage. The name extraction too is very complex:
((statsView.chart.data?.dataSets[0] as! PieChartDataSet).values[0] as! PieChartDataEntry).label!
((statsView.chart.data?.dataSets[0] as! PieChartDataSet).values[0] as! PieChartDataEntry).value
Thanks
The text was updated successfully, but these errors were encountered:
add whatever code you need to get.. The library can't forecast you need to get a label and give you a short way in advance.
Sorry, something went wrong.
No branches or pull requests
I want to add a unit test in my application that allows me to verify that the data on the Piechart is being correctly displayed.
I would therefore need to get the name and percentage value of each slice. What is the simplest way to do it?
Currently I can only extract the name of the slice and not the percentage. The name extraction too is very complex:
((statsView.chart.data?.dataSets[0] as! PieChartDataSet).values[0] as! PieChartDataEntry).label!
((statsView.chart.data?.dataSets[0] as! PieChartDataSet).values[0] as! PieChartDataEntry).value
Thanks
The text was updated successfully, but these errors were encountered: