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

How can I add the xVals to LineChartData object? #2412

Closed
vanvanj opened this issue May 4, 2017 · 2 comments
Closed

How can I add the xVals to LineChartData object? #2412

vanvanj opened this issue May 4, 2017 · 2 comments

Comments

@vanvanj
Copy link

vanvanj commented May 4, 2017

I was using a old version charts and there is a "initWithXVals: dataSets:" method in LineChartData so I can add the xVals into the chartView. But after I updated the Charts, the "initWithXVals: dataSets:" is gone. So how can I add xVals to a chartView now?

@liuxuan30
Copy link
Member

liuxuan30 commented May 5, 2017

You can't now. Read #1474
Basically, you should use valueFormatter and follow the protocol. Check out ChartsDemo as well.

@liuxuan30
Copy link
Member

liuxuan30 commented Oct 17, 2017

if the question is complex we will post code. But for APIs that already are gone, devs should check changelog or the new ChartsDemo code themselves. It's much more efficient than google and open an issue and wait for response. I admit I am not following the good habit very well but I'm trying to.

Using the demo code and walk through the change log will not take you 15 mins I guess. This is a code level library and you have all the code, rather than a black box software you don't know how it works behind the scene.

I don't copy paste the API here because I think devs should check the error message and APIs themselves. When you take some time looking at the demo code and play with it, most of your problems will be gone for sure.

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