Hi,
I have a gene expression profile; genes in rows and samples in columns, but that was not numeric, when I tried as.numerric(as.character(x))
thelling : NAs introduced by coercion
when I tried
`as.matrix(as.data.frame(lapply(x, as.numeric)))`
my file become numeric but gene names were removed from rows like below
probe cancer1 cancer2 cancer3
[1,] 27 8466 1.59275 0.35975
[2,] 28 9452 0.84700 0.15200
[3,] 29 8031 0.35325 -0.54750
[4,] 30 1735 0.24700 -0.93950
[5,] 31 9368 0.41800 0.10550
[6,] 32 3710 0.04650 -1.01075
how I can return or keep gene names in rows?
thank you
http://stackoverflow.com/questions/25694515/convert-data-frame-to-a-matrix-with-column-1-of-df-as-rownames-of-matrix