ERROR in EnrichKEGG(), 'species should be listed' in, download method do not change
1
1
Entering edit mode
Milan ▴ 10
@34d28782
Last seen 16 months ago
Belgium

Dear community, I have been stuck or something for a while now : I want to conduct a pathway analysis on my most significant list of up genes after 5 days in cultures vs d0 using the enrichKEGG() function here is the code I used : First, convert gene list in entrez_gene_ids:

Genes_up_d5_vs_d0 <- merged_counts_d5_vs_d0[merged_counts_d5_vs_d0$padj < 0.05 & merged_counts_d5_vs_d0$log2FoldChange > 1, 1:9]
mouse <- useMart("ensembl", dataset = "mmusculus_gene_ensembl")
Genes_up_d5_vs_d0 <- getBM(attributes = c("entrezgene_id", "mgi_symbol"),
                           filters = "mgi_symbol",
                           values = row.names(Genes_up_d5_vs_d0),
                           uniqueRows = TRUE, mart = mouse

Run the KEGG analysis and I get this error :

Genes_up_d5_vs_d0_KEGG <- enrichKEGG(gene=Genes_up_d5_vs_d0$entrezgene_id,
                                     organism = "mmu",
                                     qvalueCutoff = 0.05)

Reading KEGG annotation online:

fail to download KEGG data...
Error in download.KEGG.Path(species) : 
  'species' should be one of organisms listed in 'http://www.genome.jp/kegg/catalog/org_list.html'...
In addition: Warning message:
In utils::download.file(url, quiet = quiet, method = "libcurl",  :
  URL 'https://rest.kegg.jp/link/mmu/pathway': status was 'Failure when receiving data from the peer'

Checked online and I am using the correct organism code. Based on responses I've seen in other forums, it seems like a common problem (https://github.com/YuLab-SMU/clusterProfiler/issues/256), I tried the following code to see if I could resolve the problem :

R.utils::setOption("clusterProfiler.download.method","wget")
Genes_up_d5_vs_d0_KEGG <- enrichKEGG(gene=Genes_up_d5_vs_d0$entrezgene_id,
                                     organism = "mmu",
                                     qvalueCutoff = 0.05)
Reading KEGG annotation online:

fail to download KEGG data...
Error in download.KEGG.Path(species) : 
  'species' should be one of organisms listed in 'http://www.genome.jp/kegg/catalog/org_list.html'...
In addition: Warning message:
In utils::download.file(url, quiet = quiet, method = "libcurl",  :
  URL 'https://rest.kegg.jp/link/mmu/pathway': status was 'Failure when receiving data from the peer'

As you can see, the donwload method is still on "libcurl" instead of "wget" despite using the R.utils:: fonction to change. An d when I want to check if the chnage took place :

getOption("clusterProfiler.download.method")
[1] "wget"

It seems like the method was indeed changed but when I use the enrichKEGG() function it stays stuck on method="libcurl" somehow ... So I really don't understand what I am doing wrong... Any insight is welcome ! Thank all for your help ! Here is my session info :

sessionInfo()
R version 4.0.3 (2020-10-10)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 10 x64 (build 19045)

Matrix products: default

locale:
[1] LC_COLLATE=English_United Kingdom.1252  LC_CTYPE=English_United Kingdom.1252    LC_MONETARY=English_United Kingdom.1252 LC_NUMERIC=C                           
[5] LC_TIME=English_United Kingdom.1252    

attached base packages:
 [1] grid      parallel  stats4    stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
 [1] R.utils_2.12.2              R.oo_1.25.0                 R.methodsS3_1.8.2           DT_0.28                     RcisTarget_1.10.0          
 [6] ggnewscale_0.4.9            DOSE_3.16.0                 enrichplot_1.10.2           europepmc_0.4.1             ggupset_0.3.0              
[11] org.Mm.eg.db_3.12.0         org.Hs.eg.db_3.12.0         clusterProfiler_3.18.1      ComplexHeatmap_2.6.2        GSEABase_1.52.1            
[16] graph_1.68.0                annotate_1.68.0             XML_3.99-0.9                AnnotationDbi_1.52.0        tidyr_1.3.0                
[21] dplyr_1.1.2                 EnhancedVolcano_1.8.0       ggrepel_0.9.3               ggplot2_3.4.2               readxl_1.4.3               
[26] DESeq2_1.30.1               SummarizedExperiment_1.20.0 Biobase_2.50.0              MatrixGenerics_1.2.1        matrixStats_1.0.0          
[31] GenomicRanges_1.42.0        GenomeInfoDb_1.26.7         IRanges_2.24.1              S4Vectors_0.28.1            BiocGenerics_0.36.1        
[36] pheatmap_1.0.12             GSVA_1.38.2                 biomaRt_2.46.3             

loaded via a namespace (and not attached):
  [1] utf8_1.2.3             tidyselect_1.2.0       htmlwidgets_1.6.2      RSQLite_2.3.1          BiocParallel_1.24.1    scatterpie_0.1.7      
  [7] munsell_0.5.0          withr_2.5.0            colorspace_2.1-0       GOSemSim_2.16.1        ggalt_0.4.0            rstudioapi_0.15.0     
 [13] Rttf2pt1_1.3.12        labeling_0.4.2         urltools_1.7.3         GenomeInfoDbData_1.2.4 polyclip_1.10-4        bit64_4.0.5           
 [19] farver_2.1.1           downloader_0.4         vctrs_0.6.3            generics_0.1.3         BiocFileCache_1.14.0   R6_2.5.1              
 [25] ggbeeswarm_0.7.2       clue_0.3-64            graphlayouts_0.8.0     locfit_1.5-9.4         bitops_1.0-7           cachem_1.0.8          
 [31] fgsea_1.16.0           DelayedArray_0.16.3    promises_1.2.0.1       scales_1.2.1           ggraph_2.0.5           beeswarm_0.4.0        
 [37] gtable_0.3.3           ash_1.0-15             Cairo_1.6-0            tidygraph_1.2.1        rlang_1.1.1            genefilter_1.72.1     
 [43] GlobalOptions_0.1.2    splines_4.0.3          extrafontdb_1.0        BiocManager_1.30.21.1  reshape2_1.4.4         httpuv_1.6.11         
 [49] qvalue_2.22.0          extrafont_0.19         tools_4.0.3            feather_0.3.5          ellipsis_0.3.2         RColorBrewer_1.1-3    
 [55] Rcpp_1.0.11            plyr_1.8.8             progress_1.2.2         zlibbioc_1.36.0        purrr_1.0.1            RCurl_1.98-1.6        
 [61] prettyunits_1.1.1      openssl_2.0.6          GetoptLong_1.0.5       viridis_0.6.4          cowplot_1.1.1          cluster_2.1.0         
 [67] magrittr_2.0.3         data.table_1.14.8      DO.db_2.9              circlize_0.4.15        triebeard_0.4.1        hms_1.1.3             
 [73] mime_0.12              xtable_1.8-4           AUCell_1.12.0          gridExtra_2.3          shape_1.4.6            compiler_4.0.3        
 [79] tibble_3.2.1           maps_3.4.1             KernSmooth_2.23-17     crayon_1.5.2           shadowtext_0.1.2       htmltools_0.5.5       
 [85] ggfun_0.0.6            later_1.3.1            snow_0.4-4             geneplotter_1.68.0     DBI_1.1.3              tweenr_2.0.2          
 [91] dbplyr_2.3.3           proj4_1.0-12           MASS_7.3-53            rappdirs_0.3.3         Matrix_1.2-18          cli_3.6.1             
 [97] igraph_1.3.0           pkgconfig_2.0.3        rvcheck_0.2.1          xml2_1.3.5             vipor_0.4.5            XVector_0.30.0        
[103] yulab.utils_0.0.6      stringr_1.5.0          digest_0.6.33          cellranger_1.1.0       fastmatch_1.1-3        curl_5.0.1            
[109] shiny_1.7.4.1          rjson_0.2.21           lifecycle_1.0.3        jsonlite_1.8.7         viridisLite_0.4.2      askpass_1.1           
[115] fansi_1.0.4            pillar_1.9.0           lattice_0.20-41        ggrastr_1.0.2          fastmap_1.1.1          httr_1.4.6            
[121] survival_3.2-7         GO.db_3.12.1           glue_1.6.2             png_0.1-8              bit_4.0.5              ggforce_0.4.1         
[127] stringi_1.7.12         blob_1.2.4             memoise_2.0.1
KEGG DESeq2 biomaRt clusterProfiler org.Mm.eg.db • 1.9k views
ADD COMMENT
1
Entering edit mode
@james-w-macdonald-5106
Last seen 15 hours ago
United States

We do not provide support for versions of R/Bioconductor that are three years old. Please upgrade to R-4.3.0 and Bioconductor 3.17 and try again.

ADD COMMENT
1
Entering edit mode

... just to add that in this case updating is of critical importance because of change in the KEGG API that has been made on June1, 2022 (when the webservices interface moved from http to https)...!

ADD REPLY

Login before adding your answer.

Traffic: 567 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6