各位大神,我的Rstudio安装某些包的时候,如“maptools”、“e1071”等,会出现不能安装的情况(其他包能安装)出错如下:Package which is only available in source form, and may need compilation of Fortran: ‘e1071’。求问怎么解决啊?
0
各位大神,我的Rstudio安装某些包的时候,如“maptools”、“e1071”等,会出现不能安装的情况(其他包能安装)出错如下:Package which is only available in source form, and may need compilation of C/C++/Fortran: ‘e1071’。求问怎么解决啊?
没有找到相关结果
重要提示:提问者不能发表回复,可以通过评论与回答者沟通,沟通后可以通过编辑功能完善问题描述,以便后续其他人能够更容易理解问题.
1 个回复
marxsong 2016-09-13 回答
赞同来自: haobiql
> getOption('repos')
CRAN CRANextra
"https://cran.rstudio.com/" "http://www.stats.ox.ac.uk/pub/RWin"
attr(,"RStudio")
[1] TRUE
正常都可以安装:
> install.packages('e1071')
trying URL 'https://cran.rstudio.com/bin/windows/contrib/3.3/e1071_1.6-7.zip'
Content type 'application/zip' length 897449 bytes (876 KB)
downloaded 876 KB
package ‘e1071’ successfully unpacked and MD5 sums checked
The downloaded binary packages are in
C:\Users\Administrator\AppData\Local\Temp\Rtmpobqo0q\downloaded_packages
如果不行可以试试下面(国内的镜像):
install.packages('<package_name>', repo='https://mirrors.tuna.tsinghua.edu.cn/CRAN/')
China
https://mirrors.tuna.tsinghua.edu.cn/CRAN/ TUNA Team, Tsinghua University
http://mirrors.tuna.tsinghua.edu.cn/CRAN/ TUNA Team, Tsinghua University
http://mirrors.xmu.edu.cn/CRAN/ Xiamen University