Skip to content

Issues when using negative data on bar graphs #211

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

Closed
xarico10 opened this issue Jul 28, 2021 · 0 comments · Fixed by #213
Closed

Issues when using negative data on bar graphs #211

xarico10 opened this issue Jul 28, 2021 · 0 comments · Fixed by #213
Assignees

Comments

@xarico10
Copy link
Contributor

When using negative data on a stacked bar graph, some problems are happening.

x = [1980 1990 2000];
y = [15 20 -5; 10 -17 21; -10 5 15];
bar(x,y,'stacked')

fig2plotly();

Expected and generated (https://chart-studio.plotly.com/~xarico10/559/#/) plots:
Captura de Pantalla 2021-07-27 a la(s) 8 04 18 p  m
Captura de Pantalla 2021-07-27 a la(s) 8 04 40 p  m

As seen, there are many problems: On the first bar, no negative data is being plotted. On the second one, seems like if only one series is being plotted (and not reaching the correct value). On the third one only two series are being plotted.

Examples on using negative data can be found on:
https://www.mathworks.com/help/matlab/ref/bar.html#mw_4e8dc5f0-041d-417b-b88e-adf416d47558

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.

2 participants