Skip to content
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

Adding line/dataset on line chart that already has a line #2401

Closed
Kalvin126 opened this issue Apr 28, 2017 · 2 comments
Closed

Adding line/dataset on line chart that already has a line #2401

Kalvin126 opened this issue Apr 28, 2017 · 2 comments

Comments

@Kalvin126
Copy link

There does not seem to be a way to add a new line to a line chart that already has a line. We have a use case where pressing a button would add essentially a "compare to last year" line. We have to reset chart data to add the second line then animate it in. The issue is that the first line disappears, then the animation occurs on both lines.

Correct me if there is a way to do this.

@liuxuan30
Copy link
Member

open func addDataSet(_ dataSet: IChartDataSet!) in ChartData

@Kalvin126
Copy link
Author

Using addDataSet and then animate(x redraws the existing dataSet though :(

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants