Questions tagged [ios-charts]

ios-charts is a powerful chart library for iOS, written in Swift.

ios-charts is a powerful chart library for iOS, written in Swift. It is the iOS equivalent to the popular MPAndroidChart.

845 questions
3
votes
2 answers

Make barWidth fix in barchart

I am using Charts library. I want to keep chart max width fix. I didn't find any way to restrict to some width.
Santosh Singh
  • 765
  • 11
  • 27
3
votes
2 answers

Show integer value labels in bar chart for iOS

I need to create a bar graph to display some stats data, which I am able to display using iOS charts library. Only issue I am facing is that, the value labels above the bars are printed as double, I need them as integers. I have tried…
Sundeep Saluja
  • 1,089
  • 2
  • 14
  • 36
3
votes
2 answers

Integrating LineChartView in Swift 4

I am using the iOS-charts library to integrate LineChartView and I have to create below chart : So far I have achieved this : I am facing three issues here : Feb and Jun month text is missing in xAxis. Have to add Left and right space in the…
Amit
  • 4,837
  • 5
  • 31
  • 46
3
votes
2 answers

Allow PieChartView to hide labels for tiny slices in Swift

I'm making a chart by using chart iOS framework. but the value will overlay when the slice is tiny. How can I hide it? This question is similar to this GitHub link, But I don't understand how it works. Do I just need to add the code in my View…
Lester
  • 701
  • 1
  • 9
  • 47
3
votes
2 answers

How to remove all grid lines except left Y axis and bottom X axis using Charts ios?

In my app I'm using the iOS-Charts framework, and I figured out how to remove the grid (vertical and horizontal) by using: barChartView.leftAxis.drawGridLinesEnabled = false barChartView.rightAxis.drawGridLinesEnabled = false However, I still…
Eugene Gordin
  • 4,047
  • 3
  • 47
  • 80
3
votes
1 answer

ios-charts: Is it possible to show more values in marker

I am using ios-charts in swift language. I need to show more data when clicking on every circle in LineChart. I can only show one value (Y axis - in image : price without dollar sign). Is it possible to implement below image? More values, empty…
Amir Shabani
  • 690
  • 2
  • 14
  • 36
3
votes
1 answer

Add title for x & y Axis in ios charts

Hi everybody i'm working with iOS Charts iOS Charts danielgindi here i'm struggling to add a title / units for x & y axis values. help me in this image in Yaxis having the title / unit like Power(bhp) & torque(ib-ft) like this iaso want to…
Test iOS
  • 175
  • 2
  • 13
3
votes
2 answers

iOS Charts, Horizontal bars not accurate

I'm trying to get a horizontal bar chart, with real-time data changes. I got this problem though. as you can see all the bars are inaccurate except for the longest one. Following, my code. class HorizontalBarChartViewController: UIViewController…
Elia Crocetta
  • 318
  • 1
  • 6
  • 20
3
votes
0 answers

Horizontal scrolling for Time-Line chart using LineChartView

I am using LineChartView (https://github.com/danielgindi/Charts) for Time-Line chart drawing. I am facing following issue. Could anyone help me here? How to achieve scrolling in X-direction for long range values instead of making dense line…
Santosh Singh
  • 765
  • 11
  • 27
3
votes
1 answer

iOS Charts - How to initialize LineChartView programmatically

I want to use iOS charts for my objective-c project. Since the UI is written in code completely, I don't want to create a nib file for the chart view specifically. However, a simple init or initWithFrame to create the LineChartView is giving me…
jerry
  • 274
  • 2
  • 19
3
votes
2 answers

iOS swift3 Chart xaxis duplicate value issue

I have an issue creating a string value for xAxis using the iOS Charts library x value always has duplicate value, see following picture, you can see value always be JAN JAN JAN JAN FEB FEB FEB How I can setup chart's x value as it will show JAN FEB…
user2845478
  • 223
  • 4
  • 10
3
votes
1 answer

How to add marker to center position in ios charts while scrolling horizontally with increasing scaleX and enabling drag

I am using the Charts framework from Daniel Cohen Gindi. I am scrolling chart horizontally by increasing scaleX value and enabled drag as described in answer of this question Set an horizontal scroll to my Barchart in swift I want to add marker at…
Hannan Riaz
  • 33
  • 1
  • 3
3
votes
3 answers

swift/charts: chart value int instead of double

I want to turn the 1.00 and 2.00 into 1 and 2. When I try to change entry.y = Double(value) to entry.y = Int(value) it says it has to be a Double. How do I turn the values into whole numbers? var entries = [PieChartDataEntry]() for (index,…
Hunter
  • 313
  • 5
  • 20
3
votes
2 answers

Show x axis values real in danielgindi/Charts ios

I need to create a line chart in ios, so i searched and found out that danielgindi/Charts is one of the best options to use. I started using it and get the chart plotted but i need to have some changes in UI. I tried to give danielgindi LineChart…
Sudhanshu Gupta
  • 213
  • 4
  • 15
3
votes
1 answer

Reduce space between barchart and x-axis

I'm using charts in iOS to draw bar chart. But in the bar chart that I'm getting, some whitespace occurs between the bottom of the bars and the x-axis. How can I reduce or eliminate this ?
Sneha
  • 2,200
  • 6
  • 22
  • 36