Skip to content

weird breaks in hist (PR#2431)

1 message · Brian Ripley

#
I am baffled as to why you think there is a bug in R here!
On Wed, 8 Jan 2003 reinhold.koch@unibas.ch wrote:

            
It gives the expected result, period.  There is no gap, but there is a bin
with count zero.
Why is that wierd?  You requested three bins and that's what you got.
(If you didn't know you had done that, please read the help page.)
Why do you even mention that?  It's correct!  The breaks chosen are
to cover a prettified range of x.  You explicitly asked for left-open
intervals, so you got

(1,2], (2,3], (3,4]

and those do not cover the data.

Perhaps as idiot-proofing, include.lowest should not be allowed unless
`breaks' is a sequence of breakpoints.