[Rd] (PR#8376 inconsistency between plot(hist(...)) and hist(...)
clausen@econ.upenn.edu
clausen at econ.upenn.edu
Sun Dec 11 08:40:01 CET 2005
Hi Brian,
On Sun, Dec 11, 2005 at 04:34:50AM +0000, Prof Brian Ripley wrote:
> Did you check the help page? ?plot.histogram shows plot.histogram has a
> 'freq' argument, and the correct usage is
>
> plot(hist(x), freq=FALSE)
Ah, thanks for the explanation.
I didn't occur to me to check the plot.histogram() help page. Besides,
even if I had read it, I still don't think the semantics would have been
clear to me without additional experimentation.
Perhaps it might be helpful to document in the hist() help page which
attributes are stored in the hist() object. Alternatively/additionally,
hist() could emit a warning or error if plot=FALSE and irrelevant
(non-stored) attributes are set.
Cheers,
Andrew
More information about the R-devel
mailing list