R中函数enrichKEGG报错Error in download.KEGG.Path(species) :‘species‘ should be one of organisms listed in

在R中用enrichKEGG函数进行富集分析时,发现一直报错,尝试修改网络,导入library(DO.db)等网上的解决方法时都没有用,还是出现如下报错,

> kegg = enrichKEGG(genes$ENTREZID,organism = "mmu",pvalueCutoff = 1)
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 = TRUE, method = method, ...) :
  URL 'https://rest.kegg.jp/link/mmu/pathway': status was 'Couldn't connect to server'

R中函数enrichKEGG报错Error in download.KEGG.Path(species) :‘species‘ should be one of organisms listed in_第1张图片

偶然间看到jimmy老师的博客,尝试了下,解决了问题。运行下面代码即可

R中函数enrichKEGG报错Error in download.KEGG.Path(species) :‘species‘ should be one of organisms listed in_第2张图片


 install.packages("R.utils")

R.utils::setOption("clusterProfiler.download.method",'auto') 

 

 参考KEGG数据库倒闭了吗 (360doc.com)

你可能感兴趣的:(报错,R语言,r语言,开发语言)