Search code examples
iosswiftswift3ios-charts

iOS-Charts - Blank Line appears on bottom of chart


I'm using iOS-Charts and after upgrading to Swift3, I'm now noticing there is a strange blank space where the description would go at the bottom of the chart. I tried hiding the description (setting it to "" or enabled = false) but it still shows this gap. I'd prefer to just shift everything down so the 0 is nice and neat on the first line. Any ideas?

Image:

enter image description here Any ideas how to remove this?

Thanks!


Solution

  • You can set the minimum axis value so that it hide the above line try this code as

    barChartView.leftAxis.axisMinimum = 0