Skip to content
Back to formatted view

Raw Message

Message-ID: <436225EE.2010901@ozemail.com.au>
Date: 2005-10-28T13:21:50Z
From: Jim Lemon
Subject: help:simple bin problem histogram
In-Reply-To: <436BC871@minerva2.ex.ac.uk>

sp219 wrote:
> Hi,
> I cannot seem to change the default binning settings for the x axis 
> successfully using hist(). I have tried using axis() in conjunction with 
> xaxt="n", but I keep getting the error message
> Warning message:
> parameter "vect" could not be set in high-level plot() function
> can anyone help please?
> 
Hi Simon,

I didn't see a reply, but I think you want to use "breaks"

x<-sample(1:100,200,TRUE)
hist(x)
hist(x,breaks=seq(0,100,by=20))

Jim