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

Inverted y axis #21

Closed
jstuth opened this issue Jun 13, 2019 · 8 comments
Closed

Inverted y axis #21

jstuth opened this issue Jun 13, 2019 · 8 comments
Labels
enhancement New feature or request

Comments

@jstuth
Copy link
Contributor

jstuth commented Jun 13, 2019

Is it possible to add an invert axis feature, so you can have a y axis with an origin in the top left corner. This would also render the x axis + horizontal titles to the top.
I currently somehow achieved it by setting minY to the negative max value and multiply each value with -1. But the x axis and horizontal values are still on the bottom.

@imaNNeo
Copy link
Owner

imaNNeo commented Jun 13, 2019

I think if we support top and right titles you can solve your issue,
Currently we support onluy bottom and left titles, but if we support top and right, you can clear bottom titles and enable top imstead, then you can invert your chart with this solution :
Imagine you have 0 to 10 values on the y axis,
minY = 0,
maxY = 10,
And convert your points y values:
point.y = maxY - point.y
, and also draw left titles with reversed values.

@jstuth
Copy link
Contributor Author

jstuth commented Jun 13, 2019

Yes, that would help. Are you planning to add support for top and right titles?

@imaNNeo
Copy link
Owner

imaNNeo commented Jun 13, 2019

Yes, we can have this.

@imaNNeo
Copy link
Owner

imaNNeo commented Jun 13, 2019

I will mark this issue as a enhancement to add top and right titles

@jstuth
Copy link
Contributor Author

jstuth commented Jun 13, 2019

Awesome, thank you!
Any plans in which version you probably add this feature?

@imaNNeo
Copy link
Owner

imaNNeo commented Jun 13, 2019

No idea about that but it will add as soons as possible (maybe next versiom)

@imaNNeo imaNNeo added the enhancement New feature or request label Jun 13, 2019
@imaNNeo
Copy link
Owner

imaNNeo commented Jun 13, 2019

Also pull requests are welcome,
I will be happy if the community contribute on the library

@imaNNeo
Copy link
Owner

imaNNeo commented Jul 10, 2019

Hi dude, how's it going?
I did it in 0.1.3 version, check it out.
,
I close this Issue,
Thanks for your patience.

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

No branches or pull requests

2 participants