在R中安装软件包的问题

时间:2021-07-28 13:44:50

I was trying to install a package in R. However, it shows the following error

我试图在R中安装一个软件包。但是,它显示以下错误

installing *source* package ‘glasso’ ...
** package ‘glasso’ successfully unpacked and MD5 sums checked
 This package has only been tested with gfortran.
 So some checks are needed for a Fortran 90 compiler.
 R_HOME is /usr/local/Cellar/r/2.15.1/R.framework/Resources
    Unsupported Fortran 90 compiler or Fortran 90
    compilers unavailable! Stop!
ERROR: configuration failed for package ‘glasso’

Any suggestions will be much appreciated

任何建议将不胜感激

1 个解决方案

#1


1  

The versions of OSX, XCode, Fortran, R and the target package must all be compatible. (And you should have included all of those version numbers in your question.) At the moment the only thing we can tell is that you have an out-of-date version of R. Simon Urbanek provides a GNU Fortran compiler at the ATT Research website. Your machine appears improperly set up to properly dispatch to the GNU FORTRAN that you do find with your console test. If it was installed with MacPorts or Fink, it may not be in the proper directory for the R Makefile directive to XCode/make to find it.

OSX,XCode,Fortran,R和目标软件包的版本必须兼容。 (你应该在你的问题中包含所有这些版本号。)目前我们唯一能说的是你有一个过时版本的R. Simon Urbanek在ATT Research提供了一个GNU Fortran编译器网站。您的计算机似乎设置不正确,无法正确发送到您通过控制台测试找到的GNU FORTRAN。如果它与MacPorts或Fink一起安装,它可能不在R Makefile指令的正确目录中,以便XCode / make找到它。

Since the default behavior of installing a source package is to retrieve the current version of that package, you might be getting a source package that is properly mated to R 3.0.1 but not to R 2.15.1. There are older versions of glasso in the Archives if you decide to go that route.

由于安装源包的默认行为是检索该包的当前版本,因此您可能会获得与R 3.0.1正确配对但不与R 2.15.1配对的源包。如果您决定走这条路线,档案馆中会有旧版本的glasso。

But why not update to R 3.0.1 and use the current binary version? There is no apparent need for a source installation, and you appear not to have the right tools or the right skillset to do this effectively. (I'm not trying to insult you, since I struggle with these issues myself.)

但为什么不更新到R 3.0.1并使用当前的二进制版本?显然不需要源安装,并且您似乎没有合适的工具或正确的技能组来有效地执行此操作。 (我不是想侮辱你,因为我自己也在努力解决这些问题。)

#1


1  

The versions of OSX, XCode, Fortran, R and the target package must all be compatible. (And you should have included all of those version numbers in your question.) At the moment the only thing we can tell is that you have an out-of-date version of R. Simon Urbanek provides a GNU Fortran compiler at the ATT Research website. Your machine appears improperly set up to properly dispatch to the GNU FORTRAN that you do find with your console test. If it was installed with MacPorts or Fink, it may not be in the proper directory for the R Makefile directive to XCode/make to find it.

OSX,XCode,Fortran,R和目标软件包的版本必须兼容。 (你应该在你的问题中包含所有这些版本号。)目前我们唯一能说的是你有一个过时版本的R. Simon Urbanek在ATT Research提供了一个GNU Fortran编译器网站。您的计算机似乎设置不正确,无法正确发送到您通过控制台测试找到的GNU FORTRAN。如果它与MacPorts或Fink一起安装,它可能不在R Makefile指令的正确目录中,以便XCode / make找到它。

Since the default behavior of installing a source package is to retrieve the current version of that package, you might be getting a source package that is properly mated to R 3.0.1 but not to R 2.15.1. There are older versions of glasso in the Archives if you decide to go that route.

由于安装源包的默认行为是检索该包的当前版本,因此您可能会获得与R 3.0.1正确配对但不与R 2.15.1配对的源包。如果您决定走这条路线,档案馆中会有旧版本的glasso。

But why not update to R 3.0.1 and use the current binary version? There is no apparent need for a source installation, and you appear not to have the right tools or the right skillset to do this effectively. (I'm not trying to insult you, since I struggle with these issues myself.)

但为什么不更新到R 3.0.1并使用当前的二进制版本?显然不需要源安装,并且您似乎没有合适的工具或正确的技能组来有效地执行此操作。 (我不是想侮辱你,因为我自己也在努力解决这些问题。)