IOS-Charts set maximum visible x axis values : <p>I'm using ios-charts (<a href="https://github.com/danielgindi/Charts" rel="noreferrer">https://github.com/danielgindi/Charts</a>). I have a LineChartView with 12 values in the x axis.
This however is far too many to see at the same time, so I want to display only 5 and then let the user drag to the right to see the next.</p>

<p><a href="https://i.stack.imgur.com/0GzqD.png" rel="noreferrer"><img src="https://i.stack.imgur.com/0GzqD.png" alt="enter image description here"></a></p>

<p>I've tried this:</p>

<pre><code>    let chart = LineChartView()
    chart.dragEnabled = true
    chart.setVisibleXRangeMaximum(5)

    let xAxis = chart.xAxis
    xAxis.axisMinValue = 0
    xAxis.axisMaxValue = 5.0
    xAxis.setLabelsToSkip(0)
</code></pre>

<p>But still see all 11 values at the time. How can I only see 5?</p>
