ft-interactive / nightingale-charts

FT style charts, axes, scales etc
http://ft-interactive.github.io/nightingale-charts
12 stars 5 forks source link

Weird behaviour in bar and column charts when dependent axis extent sum is ~1.02 #149

Open aendra-rininsland opened 7 years ago

aendra-rininsland commented 7 years ago

Example data:

    Real earnings (excl bonuses)
Sep-11  -3.01
Oct-11  2.01

I've been debugging this for a day and feel no closer.

Creating new issue so it's easier to track than Trello.

aendra-rininsland commented 7 years ago

Produced minimalist test case; it's not an upstream issue with D3 AFAICT...

http://blockbuilder.org/aendrew/fc0b7daf67c76e680167ea96d5270de5

aendra-rininsland commented 7 years ago

Disabling this.dependentAxisScale.nice() on ln. 197 of create.js, as well as this.dependentAxisScale.range(dependentRange) on ln. 171 seems to solve the problem, but creates another — the axes don't properly update. This may be a separate issue.