Hello! I have a data frame with differential expression analysis which looks like this
head(DEedgeR)
ENTREZID logFC
<chr> <dbl>
1 10 -2.43
2 18 -1.05
3 20 1.01
4 21 2.29
5 24 2.27
6 25 1.12
I tried creating a geneList arguement like it's described here https://github.com/YuLab-SMU/DOSE/wiki/how-to-prepare-your-own-geneList
geneList = DEedgeR[,2]
names(geneList)= as.character(DEedgeR[,1]) #up until here it was okay
#but when I ran this last part
geneList = sort(geneList, decreasing = TRUE)
#I got this
Error in do.call("cbind", lapply(x, "is.na")) :
variable names are limited to 10000 bytes
I don't know what's wrong since I followed the same steps which were described on the github resource I cited above. My dataset has over 6400 genes but I guess that's not such an oddly elevated amount in this type of analysis. Also, I tried using the geneList object I created above as an argument for the gseGO function just to see what happened and I got the same error message about the 10000 bytes. Sorry if it's too silly but I really hope someone can help me!
What if you explicitly set
logFC
as numeric? Thus:geneList = as.numeric( DEedgeR[,2] )
I tried doing it like that but I got "Error: 'list' object cannot be coerced to type 'double'"
Then it seems to me that your object
DEedgeR
is not a data frame... (but maybe atibble
?) What does:class(DEedgeR)
return?Thanks! it was in fact a tibble, I first ran the
as.data.frame(DEedgeR)
command then proceeded to do it as I had already tried above and it worked! Thank you so much, I was so worried about the issue being something about the syntax or the function itself that I hadn't even thought it could be simply an object class problem.