[R] help hist some 'x' not counted; maybe 'breaks' do not span range of 'x'

Rui Barradas ruipbarradas at sapo.pt
Fri Aug 10 10:37:13 CEST 2012


Hello,

You went from 20 to 1300? What about from 20 to max(dados[[1]])?

breaks <- seq(0, max(dados[[1]]), by = 0.5)
hist(dados[[1]], breaks = breaks, ...etc...)

Hope this helps,

Rui Barradas

Em 10-08-2012 00:54, aprendiz programa escreveu:
> David,
>   I changed the command to 0 to 20 for 0 to 1300 and got no errorbut the graph does not correctly generate, because the size of the x-axis go from 0 to 1300.
> Help me!!
>> From: dcarlson at tamu.edu
>> To: aprendizprogram at hotmail.com; r-help at r-project.org
>> Subject: RE: [R] help hist   some 'x' not counted; maybe 'breaks' do not span range of 'x'
>> Date: Thu, 9 Aug 2012 15:32:55 -0500
>>
>> Use summary(dados[[1]]). The error message is telling you that the data
>> include values outside the 0 to 20 range you have specified.
>>
>>
>> ----------------------------------------------
>> David L Carlson
>> Associate Professor of Anthropology
>> Texas A&M University
>> College Station, TX 77843-4352
>>
>>> -----Original Message-----
>>> From: r-help-bounces at r-project.org [mailto:r-help-bounces at r-
>>> project.org] On Behalf Of aprendiz programa
>>> Sent: Thursday, August 09, 2012 3:13 PM
>>> To: r-help at r-project.org
>>> Subject: [R] help hist some 'x' not counted; maybe 'breaks' do not span
>>> range of 'x'
>>>
>>>
>>>
>>> Hello Guys,
>>>
>>> I would like help in script R  when I try to plot the histogram appears
>>> the error:
>>> Erro em hist.default   some 'x' not counted; maybe 'breaks' do not span
>>> range of 'x'
>>> I using a file  with more 1000 datas (vector)
>>> hist(dados[[1]], seq(0, 20, 0.5), prob=TRUE, xlab="chuva
>>> (mm/dia)",ylab="frequjncia", main="", cex.lab=1.6,
>>> cex.sub=3,cex.axis=3,cex.main=6)
>>> Please, someone could help me?
>>> Thanks
>>> Best Regards
>>> 	[[alternative HTML version deleted]]
>>
>   		 	   		
> 	[[alternative HTML version deleted]]
>
> ______________________________________________
> R-help at 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.



More information about the R-help mailing list