[R] Resetting bin size in histogram having already changed to relative frequencies
bgunter@4567 @end|ng |rom gm@||@com
Fri Aug 31 16:48:52 CEST 2018
Consult the docs, please. ?hist and the "breaks" argument. Also note the
"freq" argument, which means you should not be computing relative
"The trouble with having an open mind is that people keep coming along and
sticking things into it."
-- Opus (aka Berkeley Breathed in his "Bloom County" comic strip )
On Fri, Aug 31, 2018 at 7:42 AM Nick Wray via R-help <r-help using r-project.org>
> Hello again. I am trying to alter the bin size on a histogram where I
> have reset the vertical axis to relative frequency, rather than absolute.
> Beneath is a simple example (not my real data) of this:
> plot(h,freq=T,ylab="Relative Frequency")
> This gives me a plot with bin sizes of 0.5 and the relative frequency, but
> I cannot reset the bin size as well. I don't know whether the only way to
> do it is to reset all the h$mids etc as well but this seems horrendously
> complicated and I wonder whether I am missing something simple
> Any ideas I would be thankful for Nick Wray
> [[alternative HTML version deleted]]
> R-help using r-project.org mailing list -- To UNSUBSCRIBE and more, see
> PLEASE do read the posting guide
> and provide commented, minimal, self-contained, reproducible code.
[[alternative HTML version deleted]]
More information about the R-help