[R] Table to Data-frame
Steve Lianoglou
mailinglist.honeypot at gmail.com
Mon Aug 3 16:44:26 CEST 2009
Hi,
On Aug 3, 2009, at 10:35 AM, Olivier Peron wrote:
> Hello
>
> How to pass from table to data-frame ?
R> a <- sample(LETTERS[1:10], 20, replace=T)
R> b <- table(a)
R> c <- as.data.frame(b)
R> c
a Freq
1 A 4
2 B 2
3 C 1
4 D 4
5 E 1
6 F 1
7 H 1
8 J 6
-steve
--
Steve Lianoglou
Graduate Student: Computational Systems Biology
| Memorial Sloan-Kettering Cancer Center
| Weill Medical College of Cornell University
Contact Info: http://cbio.mskcc.org/~lianos/contact
More information about the R-help
mailing list