Entering edit mode
6.9 years ago
singhsk2622
▴
20
I used to this
mydata3 <- data.frame(sapply(mydata2, as.integer))
but now i see that row names which is gene names, has been converted to number like 1-200). but i should point that same command i used sometimes ago then it was working well. So i thought there are some proenter code hereblem with my file then i used old file on which this command was working but i am seeing same problem like gene name is converted in to number here is full script-
countsTable<-read.table("JW.txt",header=TRUE,stringsAsFactors=TRUE,row.names=1)
mydata2 <- countsTable/1000
mydata3 <- data.frame(sapply(mydata2, as.integer))
str(mydata3)
please let me know.
thnaks for comment
i used this but name is still vanishing and when i used
so getting this error Error in match.fun(FUN) : 'as.integer(as.character(mydata2))' is not a function, character or symbol In addition: Warning message: In match.fun(FUN) : NAs introduced by coercion
hi thanks!! its working now. i changed it like this.