Questions tagged [mpandroidchart]

MPAndroidChart is a powerful open-source Android chart view / graph view library. Use this tag if your question is specific to this library.

MPAndroidChart (https://github.com/PhilJay/MPAndroidChart) is a powerful open-source Android chart view / graph view library, supporting line- bar- pie- radar- bubble- and candlestick charts as well as scaling, dragging and animations.

Core features:

  • LineChart, BarChart (vertical & horizontal), PieChart, ScatterChart, CandleStickChart, RadarChart (spider web chart), BubbleChart
  • Scaling on both axes (with touch-gesture, axes separately or pinch-zoom)
  • Dragging / Panning (with touch-gesture)
  • Separate (dual) y-axes
  • Highlighting values (with customizeable popup-views)
  • Save chart to SD-Card (as image)
  • Predefined color templates
  • Legends (generated automatically, customizeable)
  • Customizeable Axes (both x- and y-axis)
  • Animations (build up animations, on both x- and y-axis)
  • Limit lines (providing additional information, maximums, ...)
  • Fully customizeable (paints, typefaces, legends, colors, background, gestures, dashed lines, ...)
  • Available as .jar file
  • Available as gradle dependency and via maven: Usage
  • Detailed documentation
  • Example Project (code for demo-application)
  • Google-PlayStore Demo Application
1939 questions
0
votes
3 answers

Changing the color of the y-axis for MPAndroidChart

Pretty basic question : how to change the color of the y-axis values in a line chart. I need the background of the chart to be a specific color, with the y-axis values being white. I need the values of the y-axis to be white, instead of…
a_local_nobody
  • 7,947
  • 5
  • 29
  • 51
0
votes
1 answer

MPAndroidchart-CombinedChart don't draw start zero?

I use mpandroidchart-combinedchart for Stock chart. the bottom chart did not start from 0,who can help me? I try chart.getAxisLeft().setAxisMinimum(0); but it didn't work.
Jsonzsl
  • 13
  • 6
0
votes
1 answer

MP android chart Linechart layout params

I want to plot 12 line graphs. So I put a linear layout inside a scrollview. I will be populating the linear layout with 12 charts. I want each chart to have height equal to width of the screen(since I am viewing graphs in landscape mode). My code…
thapro
  • 44
  • 11
0
votes
1 answer

Placing a view at a specific point on the screen

I'm trying to place a view at a specific point on the screen in Android. I have a bar chart displayed using the library MPAndroidChart and when I click a bar, I want to show another view displaying the value of the bar at the position that was…
d199224
  • 531
  • 2
  • 8
  • 23
0
votes
1 answer

adding Icons with String to MPAndroid Chart as XAxisValues

github.PhilJay:MPAndroidChart:v2.0.9` I was wondering if I can add star icons and numbers as XAxisValues like image below? I've already added the numbers and it's working fine but I don't know how to add star icons! Is there a way to combine text…
Mehdi Karimi
  • 528
  • 4
  • 25
0
votes
1 answer

type variable T with upper bounds LineChart,View

I have the following class: public class LineChart extends AppCompatActivity{ private LineChart mChart; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); …
niv
  • 15
  • 1
  • 6
0
votes
1 answer

MPAndroidChart - Timeline bar chart Android

I want to create a timeline with bars. It represents different tariff/rates during the day. For example, between 12am and 7am the rate is 10. How can I implement it using MPAndroidChart?
Yamila
  • 443
  • 1
  • 9
  • 20
0
votes
2 answers

Animate the graph by plotting each points in chart graphview android

I am using GraphView I need to display the graph points concurrently as real time. But problem is, it's displaying the graph as completely. But my requirement is, it should plot the graph concurrently. As per the suggested one, I modified based…
Shadow
  • 6,864
  • 6
  • 44
  • 93
0
votes
1 answer

How to display the chart with real time in mpandroidchart?

I am using MPAndroidChart I need to display the line chart with real time. But problem is, it's displaying after the entire completed one. Actually it should plot like real time. What I tried is, private void updateUI(final ArrayList
Shiv
  • 129
  • 3
  • 12
0
votes
1 answer

How to remove value from the Y axis in MP Android BarChart

I have created a bar graph with MPAndroid, but i want the chart minimal as possible so i removed most the description, grid and Ledgers. But i can't figure out how to remove these values from the chart.
Aslam
  • 683
  • 1
  • 7
  • 20
0
votes
3 answers

Unable resolve dependency for MPandroidChart

I'm working on Android project where I'm trying to add MPAndroidChart as follows, At project level build.gradle file I've two repositories, allprojects { repositories { jcenter() maven { url 'https://maven.google.com' } maven { url…
Atarang
  • 422
  • 1
  • 6
  • 22
0
votes
1 answer

MPAndroidChart BarChart not respecting bar width on redraw

I'm using a BarChart in an app but sometimes when I re-draw it the bars width is not respected and I get inconsistent results (even though the amount of values in the X axis is always 100). This is how I want it to look always: but sometimes it…
Franco
  • 2,711
  • 2
  • 20
  • 27
0
votes
1 answer

MPAndroid LineChart - HOW to align XAxis labels with gridlines, display XAxis values

I am new to using the MPAndroid LineChart. I have a simple code and have produced a graph as shown below: However, on this, I want to do the following: 1) To match the XAxis labels with the vertical grid lines, so that the grid lines also pass…
0
votes
1 answer

In MPAndroidChart Line graph, Interested to show data set values outside of graph top side

Please check this image, I interested to show chart like this. How can i do? I need this this my output, but need above chart result
Karthik Kompelli
  • 2,104
  • 1
  • 19
  • 22
0
votes
1 answer

MPAndroidChart refresh graph every X inputs

How to refresh graph dynamic? Init Chart. final LineData mLineData = mChart.getData(); final ILineDataSet[] xSet = {mLineData.getDataSetByIndex(0)}; final int xSetArrayItem = 0; if (xSet[xSetArrayItem] == null) { …
Esperanz0
  • 1,524
  • 13
  • 35
1 2 3
99
100