Hi r-users,
 
I would like to know how to put all the data that is greater than certain value 
in certain cell for my histogram.  For example, since maximum value of p1 is 
588 it doesn't fit in the breaks that we specified.  Can we write breaks >300? 
 
max(p1[,2])
pre.hist <- hist(p1[,2],breaks = c(0,50,100,150,200,250,300),right=FALSE)
 
> max(p1)
[1] 587.2761
> pre.hist <- hist(p1[,2],breaks = c(0,50,100,150,200,250,300),right=FALSE)
Error in hist.default(p1[, 2], breaks = c(0, 50, 100, 150, 200, 250, 300),  : 
  some 'x' not counted; maybe 'breaks' do not span range of 'x'
> max(p1[,2])
[1] 587.2761

Thank you.




      
        [[alternative HTML version deleted]]

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to