ramasamy at cancer.org.uk
Mon Jun 21 15:19:49 CEST 2004
See the example in help("cut"). You will require the option right=FALSE
in cut() or you can try hist.
x <- abs(rnorm(100))
table( cut(x, seq(0, max(ceiling(x)), by=0.5), right=FALSE ))
hist(x, breaks=seq(0, max(ceiling(x)), by=0.5), plot=FALSE)
On Mon, 2004-06-21 at 14:01, Silvia Kirkman wrote:
> I have a set of fish lengths (cm) which I'd like to
> have divided into bins as specified by myself. I want
> to classify my bins as:
> and so on...
> I'd like the frequencies to be given as a vector
> because I need to use these values for further
> Please can someone help me with this. I can't find a
> command in R that allows one to do this.
> Many thanks.
> Silvia Kirkman
> R-help at stat.math.ethz.ch mailing list
> PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
More information about the R-help