问题:使用createKEGGdb 包创建的KEGG.db_1.0.tar.gz无法安装。
一部分问题是由于windows用户没有安装Rtools软件导致的,通过安装Rtools软件可以解决。
Rtools 安装
- 下载Rtools软件
https://cran.r-project.org/bin/windows/Rtools/ - 安装Rtools
3.配置Rtools
运行R,在R的Console中输入以下代码并运行
writeLines('PATH="${RTOOLS40_HOME}\\usr\\bin;${PATH}"', con = "~/.Renviron")
4.重新启动R,使用Sys.which("make")查看结果
Sys.which("make")
## "C:\\rtools40\\usr\\bin\\make.exe"
5.本地安装R包
install.packages("KEGG.db_1.0.tar.gz", type="source")
library("KEGG.db")
另一部分问题,由于R版本升级至4.0导致KEGG.db_1.0.tar.gz包无法安装,可以使用R CMD
安装解决。
解压KEGG.db_1.0.tar.gz文件
R CMD 命令安装
在 Rstudio Terminal中 ,输入 :
R CMD build KEGG.db
R CMD install package KEGG.db_1.0.tar.gz
- 返回R中,加载包
library(KEGG.db)
>KEGG.db contains mappings based on older data because
the original resource was removed from the the
public domain before the most recent update was
produced. This package should now be considered
deprecated and future versions of Bioconductor may
not have it available. Users who want more current
data are encouraged to look at the KEGGREST or
reactome.db packages