Hi all,
I am trying to create GSEA and FGSEA for C57BL/6J Mice species. I had created a code for human species, and thought to switch out all human input as mice. However, I ran into some issues,
res <- res %>%
mutate(rank = rank(log2FoldChange, ties.method = "random"))
ens2symbol <- AnnotationDbi::select(org.Mm.eg.db,
key=res$row,
columns="SYMBOL",
keytype="ENTREZID")
Error in .testForValidKeys(x, keys, keytype, fks) : 'keys' must be a character vector
The input of column row is ENSMUSG* gmt pathway is mh.all.v2024.1.Mm.symbols.gmt
Any suggestions?
what is the class and values of
res$row
?It appeared as "NULL"
Res input is: "row","baseMean","log2FoldChange","lfcSE","stat","pvalue","padj" Data shows 7 variables with row as first column.
ENSMUSG00000101249 23365.54446 1.411235 0.3365968 4.192657 2.757065e-05 1.026079e-02
If you get
NULL
for something in R, it means it's not there. You don't show thehead
of res, but instead one row, so my guess would be the column is actually named something different like 'Row', or maybe those are therownames
rather than a column.As an example,
This was the depiction using as head(res)