-
-
Notifications
You must be signed in to change notification settings - Fork 6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How can I scroll to previous data? #3006
Comments
|
The data continues to come in, but I would like when 7-th data come in, 1-st data will disappear in chartView, The max data count of chart view is 6. How can I do this? |
have you tried |
Finally, I got a solution. let numOfVisiableData : CGFloat = 6
let scaleX = CGFloat(dataSet.values.count) / numOfVisiableData
chartView.setScaleMinima(scaleX, scaleY: 1.0)
chartView.xAxis.axisMinimum = xValueOfLastEntry - (numOfVisiableData - 1) * intervalOfX |
I have a frequently data.
Just like that:
The data will not update when I click stop monitor button.
how do I scroll from right to left to view previous data ?
The only way can scroll when I zoom out the chartView.
But I don't want to zoom out the chartView.
In my project, I will drop first data after 7th data enter,
because I would like the interval of xAxis are always same.
so the xAxis.axisMinimum will be change when data increase,
but I think that is correct way,
I don't like drop any data because when I click stop monitor button,
I would like scroll from right to left to view previous data.
So i would like :
The text was updated successfully, but these errors were encountered: