Hi,
I am trying to run a KEGG enrichment analysis on my data. My genes are in SYMBOL, which I converted to ENTREZID, but I need them in "kegg" or "ncbi-geneID" to run enrichKEGG. I looked for packages that would convert these, but they are not updated: MS_convertGene, keggConv, KEGGREST, topGO.
What worked was using the website: https://www.genome.jp/kegg/tool/conv_id.html But I have many gene lists to be converted.....
Is there any tool that I could use in R to convert these IDs in a more handy way?
Thank you. Laia
Hi Guido,
Thank you for your quick reply. Then if they match, I don't get any mapping. This is my code:
And this is the error message:
Reading KEGG annotation online:
No gene can be mapped... Expected input gene ID:
return NULL...
Warning messages: 1: In utils::download.file(url, quiet = TRUE, method = method, ...) : the 'wininet' method is deprecated for http:// and https:// URLs 2: In utils::download.file(url, quiet = TRUE, method = method, ...) : the 'wininet' method is deprecated for http:// and https:// URLs
Maybe it is important to mention that my gene list is 424 genes long? Could that be an issue?
Thank you. Laia
Please show the output from
symbol_genes[1:10]
andentrez_genes[1:10]
; thus (for example) the first 10 symbols resp. entrezids.Oops. Could it be that, because the "entrez_genes" vector is named with the symbol names, that then is not working?
Yep, that is the reason!
This is working (note the use of
as.character()
, and that in the code below no significance cutoff is applied):I keep getting the same NULL error..
'select()' returned 1:1 mapping between keys and columns
[1] "340206" "3598" "4319" NA "648947" NA "3589" "105369893" [9] NA NA
--> No gene can be mapped.... --> Expected input gene ID: --> return NULL...
Should I remove all NA? -- Nope, this did not work neither.
Also, how come you get less NA than I do?
Yours: [1] "340206" "3598" "4319" "124907722" "648947" "124903970" [7] "3589" "105369893" NA "124905027"
Mine: [1] "340206" "3598" "4319" NA "648947" NA
[7] "3589" "105369893" NA NA
No, having
NA
in your vector will work.I did notice that I retrieved only a single
NA
(8th position), but you got 4. My Bioconductor installation is up-to-date (v3.16, note this version id in that oforg.Hs.eg.db
), so this suggests you Bioconductor/package installation is not. Please check, and update if needed.Wow thanks.
[1] '3.16'
[1] '4.4.4'
[1] '3.15.0'
My clusterProfiler and org.Hs packages are the ones outdated, compared to yours. But when I run "check for package updates" it says it is up to date.... I'll update them and try again. Thanks!
Do:
BiocManager::install(version = "3.16")
.The packages are (apparently) up-to-date within Bioconductor version 3.15...
I managed installing the 3.16 version of BiocManager. R said there were 91 packages to be updated, so I did. However, some warning messages appeared. One example:
Now, if I ask what version I have for the two packages (cluster and org), they are the same as yours. But I fail to call their libraries. I get this error:
Is it ok that the downloaded packages are all going to a Temp folder?
Other warning messages:
This part is the main issue.
You should restart R and then re-install
GOSemSim
I could finally solve this and I could get KEGG results :) Thank you so much for your help and quick replies.
Best, Laia