[R] help with reshape is needed again!

xin wei xinwei at stat.psu.edu
Fri Jun 18 21:07:21 CEST 2010


hi, folks:
i need to transpose the following data:

gene    tissue    patient1     patient2     patient3.....
---------------------------------------------
gene1   breast   10            100             1
gene2   breast   20            200             4
gene3   breast   30            50              5
gene4   breast   40            400             9
................................

to the following format:

patientID  gene1  gene2   gene3    gene4............
-------------------------------------------
1              10       20       30        40
2              100     200      50        400
3               1       4          5         9

any suggestions how to use reshape or other function to achieve this?

thanks
     

-- 
View this message in context: http://r.789695.n4.nabble.com/help-with-reshape-is-needed-again-tp2260640p2260640.html
Sent from the R help mailing list archive at Nabble.com.



More information about the R-help mailing list