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
after calling .setScale('x', {min, max}), u.scales.x.min/max will actually be indices into data[0] rather than the indicated values. this is due to how the internals work to provide uniform spacing. e.g. it's not possilble to zoom in between data values when distr: 2. this will surely be re-visited anyhow as part of implementing log scales (#29).
this is surprising / non-uniform behavior, but is more of a papercut rather than a serious bug. the work-around is simply knowing that the actual scale's min has to be pulled by index from u.data[0][u.scales.x.min].
this is low priority because distr: 2 is already a niche case, and the cases when scales need to be read back after setting is even more niche. and in those cases, it's easily handled by the solution above.
The text was updated successfully, but these errors were encountered:
leeoniya
changed the title
when scales.x.distr: 2, u.scales.x.min/max are indices
when opts.scales.x.distr: 2, u.scales.x.min/max are indices
May 10, 2020
when
opts.scales.x.distr: 2
...after calling
.setScale('x', {min, max})
,u.scales.x.min/max
will actually be indices intodata[0]
rather than the indicated values. this is due to how the internals work to provide uniform spacing. e.g. it's not possilble to zoom in between data values whendistr: 2
. this will surely be re-visited anyhow as part of implementing log scales (#29).this is surprising / non-uniform behavior, but is more of a papercut rather than a serious bug. the work-around is simply knowing that the actual scale's min has to be pulled by index from
u.data[0][u.scales.x.min]
.this is low priority because
distr: 2
is already a niche case, and the cases when scales need to be read back after setting is even more niche. and in those cases, it's easily handled by the solution above.The text was updated successfully, but these errors were encountered: