安装R3.6的igraph的问题

vltsax25  于 2023-04-03  发布在  其他
关注(0)|答案(1)|浏览(203)

当我尝试使用命令install.package(“igraph”)通过R-Studio安装igraph时。在安装结束时,我收到以下消息:

gfortran -fno-optimize-sibling-calls  -fpic  -g -O2 -fdebug-prefix-map=/build/r-base-V28x5H   /r-base-3.6.3=. -fstack-protector-strong  -c AMD/Source/amd.f -o AMD/Source/amd.o
  /bin/bash: gfortran: command not found
  /usr/lib/R/etc/Makeconf:191: recipe for target 'AMD/Source/amd.o' failed
  make: *** [AMD/Source/amd.o] Error 127
 ERROR: compilation failed for package ‘igraph’
* removing ‘/home/luis/R/x86_64-pc-linux-gnu-library/3.6/igraph’
Warning in install.packages :
 installation of package ‘igraph’ had non-zero exit status

The downloaded source packages are in
‘/tmp/RtmpCofUFR/downloaded_packages’

SessionInfo()
   R version 3.6.3 (2020-02-29)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 18.04.4 LTS

Matrix products: default
BLAS:   /usr/lib/x86_64-linux-gnu/blas/libblas.so.3.7.1
LAPACK: /usr/lib/x86_64-linux-gnu/lapack/liblapack.so.3.7.1

Random number generation:
 RNG:     Mersenne-Twister 
 Normal:  Inversion 
 Sample:  Rounding 

locale:
 [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C               LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8     LC_MONETARY=en_US.UTF-8   
 [6] LC_MESSAGES=en_US.UTF-8    LC_PAPER=en_US.UTF-8       LC_NAME=C                  LC_ADDRESS=C               LC_TELEPHONE=C            
[11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C       

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

loaded via a namespace (and not attached):
[1] compiler_3.6.3 tools_3.6.3
odopli94

odopli941#

igraph有一个非常好的Troubleshooting guide,可能会有所帮助。
有一个类似的错误,什么工作对我来说是,在终端:

sudo apt install build-essential gfortran

相关问题