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

Negative numbers in line graph #134

Open
kpcyrd opened this issue Jan 22, 2018 · 9 comments · May be fixed by #199
Open

Negative numbers in line graph #134

kpcyrd opened this issue Jan 22, 2018 · 9 comments · May be fixed by #199

Comments

@kpcyrd
Copy link

kpcyrd commented Jan 22, 2018

Hey :)

I'm trying to build a line graph that can have negative numbers. After some troubleshooting I figured out that everything below 0 is cut off. I'm currently adding a 2nd number to everything to ensure the final number is positive as a workaround. This is somewhat quirky since I have to do some math while reading the graph.

Can a flag be introduced so the graph grows into negative numbers the same way it grows when increasing positive numbers?

@zlx362211854
Copy link

I have the same problem.

@make-github-pseudonymous-again

Same for bar charts

@theBliz
Copy link

theBliz commented Jan 23, 2020

got the same issue. Did anyone find a solution? @kpcyrd

@kpcyrd
Copy link
Author

kpcyrd commented Jan 24, 2020

@theBliz No. The numbers I had didn't go below -3000 so I've just added 3000 to every number and added an extra line in a different color that's always 3000 to indicate zero.

@theBliz
Copy link

theBliz commented Jan 24, 2020

Not really doable for my use case. Ended up writing a small chart page in Html

@comster comster linked a pull request Aug 30, 2020 that will close this issue
@comster
Copy link

comster commented Aug 30, 2020

I just submit a PR that solved this for me.

@devamin
Copy link

devamin commented Nov 3, 2020

Hi any update on this

@comster
Copy link

comster commented Nov 3, 2020

@devamin It would be cool if my PR was merged in, but you can checkout my fork until then.

@yrammos
Copy link

yrammos commented Apr 5, 2021

In a similar vein, I need bar graphs with negative values (or otherwise expanding downwards).

Awestruck by this library. Thank you, @yaronn.

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

Successfully merging a pull request may close this issue.

7 participants