从Github安装R-Package [英] Install R-Package from Github
问题描述
我正在尝试从Github安装软件包,但它总是向我显示相同的错误:
I am trying to install a package from Github, but it's showing me always the same error:
> install_github("jfpalomeque/Momocs")
Installing github repo Momocs/master from jfpalomeque
Downloading master.zip from https://github.com/jfpalomeque/Momocs/archive/master.zip
Installing package from C:\DOCUME~1\Ged\CONFIG~1\Temp\RtmpE15W58/master.zip
Installing Momocs
"C:/ARCHIV~1/R/R-31~1.0/bin/i386/R" --vanilla CMD INSTALL "C:\Documents and \
Settings\Ged\Configuración \
local\Temp\RtmpE15W58\devtools5a86536733\Momocs-master" \
--library="C:/Archivos de programa/R/R-3.1.0/library" --install-tests
Warning: invalid package 'C:\Documents and Settings\Ged\Configuración local\Temp\RtmpE15W58\devtools5a86536733\Momocs-master'
Error: ERROR: no packages specified
Error: Command failed (1)
我的会议
R version 3.1.0 (2014-04-10) -- "Spring Dance"
Copyright (C) 2014 The R Foundation for Statistical Computing
Platform: i386-w64-mingw32/i386 (32-bit)
推荐答案
请确保您具有devtools软件包的最新版本.目前是1.5.为此,请运行
Please make sure you have the newest version of the devtools package. This is 1.5 at the moment.To do so run
install.packages("devtools")
那么您有3个选择:
1 :)您可以尝试在devtools软件包中使用不同的参数替代方法.
1:) You can try using different parameter alternatives in the devtools package.
install_github("Momocs",username="jfpalomeque")
2 :)另一种方法是尝试下载zip文件并使用R中的常规install.packages()函数通过以下方式进行安装:
2:) Another way is trying to download the zip file and install it with the normal install.packages() function in R with:
install.packages(file_name_and_path, repos = NULL, type="source")
3 :)您也可以使用
3:) You can also just install it from cran with
install.packages("Momocs")
因为它是与github包相同的版本和相同的作者.
as it is the same version and the same author as the github package.
致谢
这篇关于从Github安装R-Package的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!