Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Install R-Package from Github

Tags:

github

r

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)

My sesion:

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)
like image 341
jfpalomeque Avatar asked Mar 19 '23 23:03

jfpalomeque


2 Answers

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")

Then you have 3 options:

1:) You can try using different parameter alternatives in the devtools package.

install_github("Momocs",username="jfpalomeque")

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:) You can also just install it from cran with

install.packages("Momocs") 

as it is the same version and the same author as the github package.

Regards

like image 79
JulianHi Avatar answered Mar 31 '23 19:03

JulianHi


You may want to try devtools::install_github("vbonhomme/Momocs") instead. As stated before, you need devtools to make it work.

Also, Momocs 1.0.0 is on CRAN so you can simply: install.packages("Momocs").

Have a look to the vignette for a nice entry point into the package. And I'm here to help if required.

like image 28
Vincent Bonhomme Avatar answered Mar 31 '23 18:03

Vincent Bonhomme