Re: [R] Odp: create frequency table

From: T.D.Rudolph <prairie.picker_at_gmail.com>
Date: Tue, 27 May 2008 12:25:00 -0700 (PDT)

This definitely does the trick.
I knew there was an easier way!

Petr Pikal wrote:

> 
> r-help-bounces_at_r-project.org napsal dne 27.05.2008 09:31:16:
> 

>>
>> Hi Petr
>>
>> My mistake in omitting "replace=T" in the first part.
>> Unfortunately I oversimplified my problem as I'm not actually dealing
> with

>> whole numbers but numerous significant digits, therefore the table
> option

>> will not assist me in this case. My bin size will vary to the order of
>> 0.05-1.
>>
>> Perhaps try these instead:
>> x <- rnorm(1:100)
>> z<-seq(from=-2.5, to=3.5, by=0.5)
> 
> OK, then you can use table with cut and maybe findInterval as mentioned in 
> help page.
> e.g.
> table(cut(x,c(-Inf, z, +Inf)))
> 
> Regards
> Petr
> 
> 

>>
>> Cheers,
>> Tyler
>>
>> ______________________________________________
>> 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.
>>
>>
>>
>> --
>> View this message in context:
> http://www.nabble.com/create-frequency-table-

>> tp17481748p17484689.html
>> Sent from the R help mailing list archive at Nabble.com.
>>
>> ______________________________________________
>> 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.
> 
> ______________________________________________
> 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.
> 
> 

-- 
View this message in context: http://www.nabble.com/create-frequency-table-tp17481748p17498094.html
Sent from the R help mailing list archive at Nabble.com.

______________________________________________
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.
Received on Tue 27 May 2008 - 21:45:35 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Tue 27 May 2008 - 22:30:45 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive