Create Multicolored Pie Chart in Android Studio - android

My app contain a quiz in which I want to show the result of the quiz in a graphical form.
But I don't know about how to create drawable shapes dynamically, and with a pie chart design.
The App has three parameters:
Correct questions
Incorrect questions
Not attempted questions
I have no idea about how to design a pie chart dynamically and I want to add it to a linear layout.
The graphical representation of result will be like following diagram:
How can I solve this?

There is a very famous library for this the MPAndroidChart .
Using this you can create all types of graphical representation like pie charts,line charts ,bar charts and many more.
The image in your question is a pie chart and to get started with it , you can view this tutorial here.

you can use this library to build the pie chart here as you mentioned in the image

Related

Android customised box plot chart

How do I implement a box plot graph on Android like this? It seems to be similar to CandleStick Chart of MPAndroidChart. Is there any other good way?
The CandleStickChart is the closest match to your requirement for that library in MPAndroidChart although you could have a look at the other chart libraries here
to see if there is anything closer.
The CandleStickChart from MPAndroidChart looks like this:
CandleStickChartActivity in the example GitHub project is a good start for you to base your implementation.
If you need to customise the appearance of the chart further (e.g., to use circles instead of boxes) you will need to write a custom renderer. See this question for how to do that.

IS there any way so that i can apply animations on charts using AChartEngine

I'm using AchartEngine to create charts in android. But not able to show animations. For example : in pies chart i want initial rotations. In bar chart i want bar should grow from top to bottom.
Or is there any API or library which helps to build animated charts in android.
Please suggests or give any sample.
It is possible. You just need to modify the property you want to be modified and then call mChartView.repaint();

How to Draw custom Bar charts in Android

I am developing an application, in which there is a requirement for showing results in a Bar charts. I have tried developing charts using AChartEngine and Google api and many other apis. But my Requirement is to draw multiple charts in one Activity. I followed this.Its working fine. But when i try to set the background image for the whole screen, Its not working
Can Anybody help me please
Just check this Bar Chart in Android With out any Built in jars. Here you can draw charts without any built in jars. Its just simple Graph creation using the concept of setting the height for the textview in a ListView.
I implemented this by using the Horizontal ListView. Here you have the two double arrays with equal size of elements. And the graph will adjust according to the orientation(Portrait and landscape).
If you want more charts in one activity, you can implement another Horizontal Listview in the layout.
I hope this will help you....
i can help you with paid Library which is nice
is called aiCharts (Bar Charts)
or you should refer GraphViewDemo it is also anice and free libraray to make bar graph
GraphViewDemo
I am writing a blog post on the subject. For one of my clients I created a compound view with an embedded bar chart. I did not find a simple and flexible library to achieve this, so I decided to go with custom views. To my surprise, it was simpler than I had expected: create a custom view that takes a colour and a percentage as attributes and use linear layouts to contain its instances, using layout_weight or a fixed layout_width to maintain proportions. I am very happy with the results.

how to change the chart UI when using Achartengine in android?

when using Achartengine for drawing a chart , the function of Achartengine library will just provide a intent, then you just need to jump to the screen pointing by the intent ; yes .... this can be work perfect .. However , the screen is so simple and the style of the chart screen is totally uncompatible with other screen's , and it seems that the Achartengine library doesn't provide any interface to change the chart UI ( not just the color of line or point), can any one tell me some idea to solve this issue...
any help will be appreciated!
bob
The AChartEngine APIs actually allow you create views as well. This means that you can have a chart together with other UI components under the same screen. There is example code in the AChartEngine demo showing you how to do this.
If you apply an application wide theme through your manifest you will inherit some of them. Things like background colors, etc. Otherwise you have to specify your text/axis/line colors through code when setting up the intent.

Displaying clickable pie charts in android app

Can any one please tell me is it possible to display pie chart in our application.
Do we need to use any third party api. I want to display pie chart with click event to each slice in the chart.
May this can helps: GraphView
Is a library to create charts on Android. On the same page you can find code examples. Source code here
Other option is: achartengine
Related questions:
https://stackoverflow.com/questions/424752/any-good-graphing-packages-for-android
Hope it helps!
You can use AChartEngine for clickable pie charts.
An example showing this usage can be found here.

Categories

Resources