Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/r/64.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
无法安装ggpubr_R_Installation_Ggpubr - Fatal编程技术网

无法安装ggpubr

无法安装ggpubr,r,installation,ggpubr,R,Installation,Ggpubr,我正在尝试下载软件包ggpubr。我的R studio版本是3.5.2。我一直试图通过以下方式安装ggpubr库: install.packages("ggpubr") 及 但当我这么做的时候,我得到了这个错误: clang: error: unsupported option '-fopenmp' make: *** [RcppExports.o] Error 1 ERROR: compilation failed for package ‘co

我正在尝试下载软件包
ggpubr
。我的R studio版本是3.5.2。我一直试图通过以下方式安装
ggpubr
库:

install.packages("ggpubr")

但当我这么做的时候,我得到了这个错误:


    clang: error: unsupported option '-fopenmp'
    make: *** [RcppExports.o] Error 1
    ERROR: compilation failed for package ‘conquer’
    * removing ‘/Library/Frameworks/R.framework/Versions/3.5/Resources/library/conquer```
    
#Followed by:
    
    ../libtool: line 1099: ERROR:: command not found
    make[2]: *** [libutil.la] Error 127
    make[1]: *** [all-recursive] Error 1
    make: *** [all] Error 2
    ERROR: configuration failed for package ‘nloptr’
    * removing ‘/Library/Frameworks/R.framework/Versions/3.5/Resources/library/nloptr’
    Warning in install.packages :
      installation of package ‘nloptr’ had non-zero exit status
    ERROR: dependency ‘conquer’ is not available for package ‘quantreg’
    * removing ‘/Library/Frameworks/R.framework/Versions/3.5/Resources/library/quantreg’
    Warning in install.packages :
      installation of package ‘quantreg’ had non-zero exit status
    ERROR: dependency ‘nloptr’ is not available for package ‘lme4’
    * removing ‘/Library/Frameworks/R.framework/Versions/3.5/Resources/library/lme4’
    Warning in install.packages :
      installation of package ‘lme4’ had non-zero exit status
    ERROR: dependencies ‘pbkrtest’, ‘quantreg’, ‘lme4’ are not available for package ‘car’
    * removing ‘/Library/Frameworks/R.framework/Versions/3.5/Resources/library/car’
    Warning in install.packages :
      installation of package ‘car’ had non-zero exit status
    ERROR: dependency ‘car’ is not available for package ‘rstatix’
    * removing ‘/Library/Frameworks/R.framework/Versions/3.5/Resources/library/rstatix’
    Warning in install.packages :
      installation of package ‘rstatix’ had non-zero exit status
    ERROR: dependency ‘rstatix’ is not available for package ‘ggpubr’
    * removing ‘/Library/Frameworks/R.framework/Versions/3.5/Resources/library/ggpubr’
    Warning in install.packages :
      installation of package ‘ggpubr’ had non-zero exit status
我不知道该怎么办。我已经尝试过独立安装
conquer
,还有一些其他没有用的东西

我尝试过简单地使用
install.package(“ggpubr”)
,我也尝试过
if(!require(devtools))install.packages(“devtools”)devtools::install\u github(“kassambara/ggpubr”)


有人知道该怎么做吗?

其中一个依赖项仅适用于
R>=4
,因此您需要手动安装较旧版本的
nloptr

解决方案是手动安装较旧版本的依赖项(nloptr):

资料来源:


    clang: error: unsupported option '-fopenmp'
    make: *** [RcppExports.o] Error 1
    ERROR: compilation failed for package ‘conquer’
    * removing ‘/Library/Frameworks/R.framework/Versions/3.5/Resources/library/conquer```
    
#Followed by:
    
    ../libtool: line 1099: ERROR:: command not found
    make[2]: *** [libutil.la] Error 127
    make[1]: *** [all-recursive] Error 1
    make: *** [all] Error 2
    ERROR: configuration failed for package ‘nloptr’
    * removing ‘/Library/Frameworks/R.framework/Versions/3.5/Resources/library/nloptr’
    Warning in install.packages :
      installation of package ‘nloptr’ had non-zero exit status
    ERROR: dependency ‘conquer’ is not available for package ‘quantreg’
    * removing ‘/Library/Frameworks/R.framework/Versions/3.5/Resources/library/quantreg’
    Warning in install.packages :
      installation of package ‘quantreg’ had non-zero exit status
    ERROR: dependency ‘nloptr’ is not available for package ‘lme4’
    * removing ‘/Library/Frameworks/R.framework/Versions/3.5/Resources/library/lme4’
    Warning in install.packages :
      installation of package ‘lme4’ had non-zero exit status
    ERROR: dependencies ‘pbkrtest’, ‘quantreg’, ‘lme4’ are not available for package ‘car’
    * removing ‘/Library/Frameworks/R.framework/Versions/3.5/Resources/library/car’
    Warning in install.packages :
      installation of package ‘car’ had non-zero exit status
    ERROR: dependency ‘car’ is not available for package ‘rstatix’
    * removing ‘/Library/Frameworks/R.framework/Versions/3.5/Resources/library/rstatix’
    Warning in install.packages :
      installation of package ‘rstatix’ had non-zero exit status
    ERROR: dependency ‘rstatix’ is not available for package ‘ggpubr’
    * removing ‘/Library/Frameworks/R.framework/Versions/3.5/Resources/library/ggpubr’
    Warning in install.packages :
      installation of package ‘ggpubr’ had non-zero exit status
packageurl<-"https://cran.r-project.org/src/contrib/Archive/nloptr/nloptr_1.2.1.tar.gz"
install.packages(packageurl, repos=NULL, type="source")