You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I had a problem with y values in diverging barcharts. If dy == 0, it is converted as positive datapoints group. But 0 is neither positive nor negative. Therefore is group of negative datapoints, where value is 0, not more correct converted. I changed in your example some data values to 0 and you can see results: https://jsfiddle.net/oy21nzq0/1/ . Negative datapoints had in your example cherries and dates. You can see in console d3.stack() converted arrays for each group.
I.e. for cherries look likes this:
d3-shape/src/offset/diverging.js
Line 5 in b8279d6
Hi,
I had a problem with y values in diverging barcharts. If dy == 0, it is converted as positive datapoints group. But 0 is neither positive nor negative. Therefore is group of negative datapoints, where value is 0, not more correct converted. I changed in your example some data values to 0 and you can see results: https://jsfiddle.net/oy21nzq0/1/ . Negative datapoints had in your example cherries and dates. You can see in console d3.stack() converted arrays for each group.
I.e. for cherries look likes this:
how you see 0 and 2 are not correct. Both are positive. Correct is below:
I fixed this problem, where I changed d3.stackOffsetDiverging https://jsfiddle.net/oy21nzq0/ . Please Check this FIX and say, if it's a good solution.
Best Regards
Davit
The text was updated successfully, but these errors were encountered: