R

时间:2018-10-15 13:32:17

标签: r

美好的一天。我安装agricolae软件包时遇到问题(R版本是3.2.3。当我输入install.packages("agricolae")时,我有以下问题:

Installing package into ‘C:/Users/(User name)/Documents/R/win-library/3.2’
(as ‘lib’ is unspecified)
Warning in install.packages :
  dependency ‘spdep’ is not available
also installing the dependencies ‘httpuv’, ‘later’, ‘promises’, ‘shiny’, ‘miniUI’, ‘questionr’, ‘klaR’


  There are binary versions available but the source versions are later:
          binary  source needs_compilation
httpuv     1.3.3   1.4.5              TRUE
shiny      1.0.2   1.1.0             FALSE
miniUI     0.1.1 0.1.1.1             FALSE
questionr  0.6.0   0.6.3             FALSE
klaR      0.6-12  0.6-14             FALSE
agricolae  1.2-4   1.2-8             FALSE

Do you want to install from sources the package which needs compilation?
y/n: y
Packages which are only available in source form, and may need compilation of C/C++/Fortran:
  ‘later’ ‘promises’
Do you want to attempt to install these from sources?
y/n: y
installing the source packages ‘httpuv’, ‘later’, ‘promises’, ‘shiny’, ‘miniUI’, ‘questionr’, ‘klaR’, ‘agricolae’

下载所有软件包后,Rstudio会向我显示以下内容:

* installing *source* package 'later' ...
** package 'later' successfully unpacked and MD5 sums checked

   **********************************************
   WARNING: this package has a configure script
         It probably needs manual configuration
   **********************************************
     

**库

     

***拱-i386

     

g ++ -m32 -I“ C:/PROGRA~1/R/R-32~1.3/include” -DNDEBUG   -DTHREADS_H_SUPPORT = -1 -I“ C:/用户/(用户名)/Documents/R/win-library/3.2/Rcpp/include” -I“ C:/用户/(用户   名称)/Documents/R/win-library/3.2/BH/include“   -I“ d:/ RCompile / r-compiling / local / local323 / include” -O2 -Wall -mtune = core2 -c RcppExports.cpp -o RcppExports.o

     

g ++ -m32 -I“ C:/PROGRA~1/R/R-32~1.3/include” -DNDEBUG   -DTHREADS_H_SUPPORT = -1 -I“ C:/用户/(用户名)/Documents/R/win-library/3.2/Rcpp/include” -I“ C:/用户/(用户   名称)/Documents/R/win-library/3.2/BH/include“   -I“ d:/ RCompile / r-compiling / local / local323 / include” -O2 -Wall -mtune = core2 -c callback_registry.cpp -o callback_registry.o

     

gcc -m32 -I“ C:/PROGRA~1/R/R-32~1.3/include” -DNDEBUG   -DTHREADS_H_SUPPORT = -1 -I“ C:/用户/(用户名)/Documents/R/win-library/3.2/Rcpp/include” -I“ C:/用户/(用户   名称)/Documents/R/win-library/3.2/BH/include“   -I“ d:/ RCompile / r-compiling / local / local323 / include” -O3 -Wall -std = gnu99 -mtune = core2 -c init.c -o init.o

     

g ++ -m32 -I“ C:/PROGRA~1/R/R-32~1.3/include” -DNDEBUG   -DTHREADS_H_SUPPORT = -1 -I“ C:/用户/(用户名)/Documents/R/win-library/3.2/Rcpp/include” -I“ C:/用户/(用户   名称)/Documents/R/win-library/3.2/BH/include“   -I“ d:/ RCompile / r-compiling / local / local323 / include” -O2 -Wall -mtune = core2 -c Later.cpp -o Later.o

     

g ++ -m32 -I“ C:/PROGRA~1/R/R-32~1.3/include” -DNDEBUG   -DTHREADS_H_SUPPORT = -1 -I“ C:/用户/(用户名)/Documents/R/win-library/3.2/Rcpp/include” -I“ C:/用户/(用户   名称)/Documents/R/win-library/3.2/BH/include“   -I“ d:/ RCompile / r-compiling / local / local323 / include” -O2 -Wall -mtune = core2 -c Later_native.cpp -o Later_native.o

     

g ++ -m32 -I“ C:/PROGRA~1/R/R-32~1.3/include” -DNDEBUG   -DTHREADS_H_SUPPORT = -1 -I“ C:/用户/(用户名)/Documents/R/win-library/3.2/Rcpp/include” -I“ C:/用户/(用户   名称)/Documents/R/win-library/3.2/BH/include“   -I“ d:/ RCompile / r-compiling / local / local323 / include” -O2 -Wall -mtune = core2 -c Later_posix.cpp -o Later_posix.o

     

g ++ -m32 -I“ C:/PROGRA~1/R/R-32~1.3/include” -DNDEBUG   -DTHREADS_H_SUPPORT = -1 -I“ C:/用户/(用户名)/Documents/R/win-library/3.2/Rcpp/include” -I“ C:/用户/(用户   名称)/Documents/R/win-library/3.2/BH/include“   -I“ d:/ RCompile / r-compiling / local / local323 / include” -O2 -Wall -mtune = core2 -c Later_win32.cpp -o Later_win32.o

     

g ++ -m32 -I“ C:/PROGRA~1/R/R-32~1.3/include” -DNDEBUG   -DTHREADS_H_SUPPORT = -1 -I“ C:/用户/(用户名)/Documents/R/win-library/3.2/Rcpp/include” -I“ C:/用户/(用户   名称)/Documents/R/win-library/3.2/BH/include“   -I“ d:/ RCompile / r-compiling / local / local323 / include” -O2 -Wall -mtune = core2 -c timer_posix.cpp -o timer_posix.o

     

g ++ -m32 -I“ C:/PROGRA~1/R/R-32~1.3/include” -DNDEBUG   -DTHREADS_H_SUPPORT = -1 -I“ C:/用户/(用户名)/Documents/R/win-library/3.2/Rcpp/include” -I“ C:/用户/(用户   名称)/Documents/R/win-library/3.2/BH/include“   -I“ d:/ RCompile / r-compiling / local / local323 / include” -O2 -Wall -mtune = core2 -c timestamp_unix.cpp -o timestamp_unix.o

     

g ++ -m32 -I“ C:/PROGRA~1/R/R-32~1.3/include” -DNDEBUG   -DTHREADS_H_SUPPORT = -1 -I“ C:/用户/(用户名)/Documents/R/win-library/3.2/Rcpp/include” -I“ C:/用户/(用户   名称)/Documents/R/win-library/3.2/BH/include“   -I“ d:/ RCompile / r-compiling / local / local323 / include” -O2 -Wall -mtune = core2 -c timestamp_win32.cpp -o timestamp_win32.o

     

gcc -m32 -I“ C:/PROGRA~1/R/R-32~1.3/include” -DNDEBUG   -DTHREADS_H_SUPPORT = -1 -I“ C:/用户/(用户名)/Documents/R/win-library/3.2/Rcpp/include” -I“ C:/用户/(用户   名称)/Documents/R/win-library/3.2/BH/include“   -I“ d:/ RCompile / r-compiling / local / local323 / include” -O3 -Wall -std = gnu99 -mtune = core2 -c tinycthread / tinycthread.c -o tinycthread / tinycthread.o

     

g ++ -m32 -shared -s -static-libgcc -o Later.dll tmp.def RcppExports.o   callback_registry.o init.o Later.o Later_native.o Later_posix.o   later_win32.o timer_posix.o timestamp_unix.o timestamp_win32.o   ./tinycthread/tinycthread.o   -Ld:/ RCompile / r-编译/本地/ local323 / lib / i386 -Ld:/ RCompile / r-编译/本地/ local323 / lib -LC:/PROGRA~1/R/R-32~1.3/bin/ i386 -lR

     

./ tinycthread / tinycthread.o:tinycthread.c :(。text + 0x5a9):未定义   引用“ _imp ___ ftime_s”

     

./ tinycthread / tinycthread.o:tinycthread.c :(。text + 0x9b0):未定义   引用“ _imp ___ ftime_s”

     

./ tinycthread / tinycthread.o:tinycthread.c :(。text + 0xbc9):未定义   引用“ _imp ___ ftime_s”

     

./ tinycthread / tinycthread.o:tinycthread.c :(。text + 0xec9):未定义   引用“ _imp ___ ftime_s”

     

collect2:ld返回1个退出状态

     

未创建DLL

     

错误:软件包“以后”的编译失败

     

删除“ C:/用户/(用户名)/Documents/R/win-library/3.2/later”

     

install.packages中的警告:正在运行的命令   '“ C:/PROGRA~1/R/R-32~1.3/bin/x64/R” CMD安装-l“ C:\ Users(User   名称)\ Documents \ R \ win-library \ 3.2“ C:\ Users(用户   名称)\ AppData \ Local \ Temp \ Rtmpi439vE / downloaded_pa​​ckages / later_0.7.5.tar.gz'   状态为1

     

install.packages中的警告:安装软件包“以后”   非零退出状态错误:依赖项“以后”不适用于   包“承诺”   删除“ C:/用户/(用户名)/Documents/R/win-library/3.2/promises”

     

install.packages中的警告:正在运行的命令   '“ C:/PROGRA~1/R/R-32~1.3/bin/x64/R” CMD安装-l“ C:\ Users(User   名称)\ Documents \ R \ win-library \ 3.2“ C:\ Users(用户   名称)\ AppData \ Local \ Temp \ Rtmpi439vE / downloaded_pa​​ckages / promises_1.0.1.tar.gz'   状态为1

     

install.packages中的警告:安装了“ promises”软件包   非零退出状态错误:依赖项“承诺”,“以后”不是   可用于“ httpuv”软件包   删除“ C:/用户/(用户名)/Documents/R/win-library/3.2/httpuv”

     

install.packages中的警告:正在运行的命令   '“ C:/PROGRA~1/R/R-32~1.3/bin/x64/R” CMD安装-l“ C:\ Users(User   名称)\ Documents \ R \ win-library \ 3.2“ C:\ Users(用户   名称)\ AppData \ Local \ Temp \ Rtmpi439vE / downloaded_pa​​ckages / httpuv_1.4.5.tar.gz'   状态为1

     

install.packages中的警告:安装了“ httpuv”软件包   非零退出状态错误:依赖项“ httpuv”,“以后”,“承诺”   不适用于“闪亮”套餐   删除“ C:/用户/(用户名)/Documents/R/win-library/3.2/shiny”

     

install.packages中的警告:正在运行的命令   '“ C:/PROGRA~1/R/R-32~1.3/bin/x64/R” CMD安装-l“ C:\ Users(User   名称)\ Documents \ R \ win-library \ 3.2“ C:\ Users(用户   名称)\ AppData \ Local \ Temp \ Rtmpi439vE / downloaded_pa​​ckages / shiny_1.1.0.tar.gz'   状态为1

     

install.packages中的警告:安装了“ shiny”软件包   非零退出状态

     

错误:依赖项“ shiny”不适用于软件包“ miniUI”   删除“ C:/用户/(用户名)/Documents/R/win-library/3.2/miniUI”

     

install.packages中的警告:正在运行的命令   '“ C:/PROGRA~1/R/R-32~1.3/bin/x64/R” CMD安装-l“ C:\ Users(User   名称)\ Documents \ R \ win-library \ 3.2“ C:\ Users(用户   名称)\ AppData \ Local \ Temp \ Rtmpi439vE / downloaded_pa​​ckages / miniUI_0.1.1.1.tar.gz'   状态为1

     

install.packages中的警告:安装了软件包“ miniUI”   非零退出状态错误:依赖项“ shiny”,“ miniUI”不是   可用于“ questionr”包

     

删除“ C:/用户/(用户名)/Documents/R/win-library/3.2/questionr”   install.packages中的警告:

     

运行命令'“ C:/PROGRA~1/R/R-32~1.3/bin/x64/R” CMD INSTALL -l   “ C:\ Users(用户名)\ Documents \ R \ win-library \ 3.2” C:\ Users(用户   名称)\ AppData \ Local \ Temp \ Rtmpi439vE / downloaded_pa​​ckages / questionr_0.6.3.tar.gz'   状态为1

     

install.packages中的警告:安装软件包“ questionr”   退出状态为非零错误:依赖项“ questionr”不是   可用于软件包“ klaR”

     

删除“ C:/用户/(用户名)/Documents/R/win-library/3.2/klaR”

     

install.packages中的警告:正在运行的命令   '“ C:/PROGRA~1/R/R-32~1.3/bin/x64/R” CMD安装-l“ C:\ Users(User   名称)\ Documents \ R \ win-library \ 3.2“ C:\ Users(用户   名称)\ AppData \ Local \ Temp \ Rtmpi439vE / downloaded_pa​​ckages / klaR_0.6-14.tar.gz'   状态为1

     

install.packages中的警告:安装了软件包“ klaR”   非零退出状态错误:依赖项“ klaR”,“ spdep”不是   可用于“ agricolae”软件包

     

删除“ C:/用户/(用户名)/Documents/R/win-library/3.2/agricolae”

     

install.packages中的警告:

     

运行命令'“ C:/PROGRA~1/R/R-32~1.3/bin/x64/R” CMD INSTALL -l   “ C:\ Users(用户名)\ Documents \ R \ win-library \ 3.2” C:\ Users(用户   名称)\ AppData \ Local \ Temp \ Rtmpi439vE / downloaded_pa​​ckages / agricolae_1.2-8.tar.gz'   状态为1

     

install.packages中的警告:

     

安装软件包“ agricolae”的退出状态为非零

     

下载的源程序包位于‘C:\ Users(User   名称)\ AppData \ Local \ Temp \ Rtmpi439vE \ downloaded_pa​​ckages”

任何想法如何解决?谢谢!

1 个答案:

答案 0 :(得分:0)

R版本有问题。尝试将R安装更新到> = 3.5,就可以了。