Re: [R] distribution of daily rainfall values in binned categories

From: Francisco J. Zagmutt <>
Date: Wed 28 Jun 2006 - 13:51:31 EST

Hi Etienne,

Somebody asked a somehow related question recently.

Take a look at cut? table? and barplot?
#Creates fake data from uniform(0,30)

x=runif(50, 0,30)

#Creates categories
rain=cut(x,breaks=c( 0, 1,2.5,5, 10, 20, Inf))

#Creates contingency table of categories tab=table(rain)

#Plots frequencies of rainfall

I hope this helps!


Dr. Francisco J. Zagmutt
College of Veterinary Medicine and Biomedical Sciences Colorado State University

>From: etienne <>
>Subject: [R] distribution of daily rainfall values in binned categories
>Date: Tue, 27 Jun 2006 11:28:59 -0700 (PDT)
>I'm a newbie in using R and I would like to have a few
>clues as to how I could compute and plot a
>distribution of daily rainfall intensity in different
>categories. I have daily values (mm/day) for several
>years and I need to show the frequency of 0-1, 1-2.5,
>2.5-5, 5-10, 10-20, 20+ mm/day. Can this be done
> mailing list
>PLEASE do read the posting guide!
> mailing list PLEASE do read the posting guide! Received on Wed Jun 28 15:11:37 2006

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.1.8, at Wed 28 Jun 2006 - 20:13:13 EST.

Mailing list information is available at Please read the posting guide before posting to the list.