Closed espears4sq closed 6 years ago
Ah, this appears to be a duplicate of #669 and was fixed, but I don't have the ability to use the updated version of breeze with the fix.
So the culprit is actually in this old implementation of rangeD
that used floor
instead of ceil
with the extra step adjustment.
In the algorithm for how
binEdges
is calculated inbreeze.stats.hist
, there can be cases whereend + (end - start) / bins
will end up being exactly equal to the final step point, and thus not included sincerangeD
looks for values strictly less than the endpoint.Here's an example where using two bins ought to provide 3 locations for
binEdges
, but instead it only provides 2.I thought it must be something to do with an integer multiple of the stepsize hitting a boundary condition, but it seems more complicated than that.