Another way to install R packages from Github

Another way to install R packages from Github

The R/RStudio installation instructions mention two ways of installing R packages from Github. 7-A installing using devtools and 7-B installing from local zip. The second method can be slightly simplified for R packages that have a release on Github.

Instead of downloading the .zip, go to the release and under Assets download the .tar.gz (bottom link in screenshot below). Then, run install.packages directly on this file, no need to unzip: 'install.packages("C:/path to package.tar.gz", repos = NULL)'.


This method has two small benefits: no need to unzip and you don't have the risk that you install an unreleased/untested version of the package. It is also possible in this way to choose which version you want to install.

On a general note; the instructions have been very helpful to set up R and RStudio. Great that domain whitelisting is now possible.