我正在尝试在R上安装WGCNA软件包,但出现以下错误:
> *** caught segfault *** address (nil), cause 'memory not mapped' An irrecoverable exception occurred. R is aborting now ... Segmentation
> fault (core dumped) ERROR: loading failed
> * removing ‘/home/hpc/R/x86_64-pc-linux-gnu-library/3.4/WGCNA’ *** caught segfault *** address (nil), cause 'memory not mapped'
>
> Traceback: 1: q("no", status = status, runLast = FALSE) 2:
> do_exit(status = status) 3: do_exit_on_error() 4: errmsg("loading
> failed") 5: do_install_source(pkg_name, instdir, pkg, desc) 6:
> do_install(pkg) 7: tools:::.install_packages() An irrecoverable
> exception occurred. R is aborting now ... Segmentation fault (core
> dumped)
有人知道如何安装吗? 非常感谢 安德里亚
答案 0 :(得分:0)
在全新的R会话期间发生此错误,对吗? 如果是这样,请使用以下代码删除已安装的软件包并重新安装它们。我认为这可以解决您的问题。
ip <- installed.packages()
pkgs.to.remove <- ip[!(ip[,"Priority"] %in% c("base", "recommended")), 1]
sapply(pkgs.to.remove, remove.packages)
sapply(pkgs.to.remove, install.packages)