[R] Crosstab from sql dump

Alan Gibson alan.gibson at gmail.com
Sat Dec 30 14:00:20 CET 2006


Hello all,,

Im looking for a simple function to produce a crosstab from a dumped
sql query result. Its very hard to produce crosstabs with most
databases (Access being the exception), so with the vast array of R
packages, Im sure this has to have already been implemented somewhere.

Examples are always good:
Take a csv dump like

name code
user1 100
user2 100
user1 200
user2 210
user1 300
user2 300

and produce

user1 user2
100 100
200 210
300 300

Thanks in advance for any suggestions,

Alan



More information about the R-help mailing list