Tackling the Windows Installation Issue of R packages: slidify, slidifyLibraries, and rCharts

January 8, 2016 at 4:55 AMSteven Wang

Slidify is an R package helps to create and publish beautiful HTML5 presentations from RMarkdown. Slidify package is fantastic for creating reproducible presentations.

slidifyLibraries contains external resources used by Slidify.

rCharts is an R package to create, customize and publish interactive javascript visualizations from R using a familiar lattice style plotting interface.

All of these three packages are created and maintained by Ramnath Vaidyanathan of McGill University.  Since all these three packages are not on CRAN and needs to be installed from github using the Hadley's devtools package.


library(devtools)

install_github('ramnathv/slidify')

install_github('ramnathv/slidifyLibraries')

install_github('ramnathv/rCharts')


As Ramnath mentioned in one of this Slidify workshop, While the installation process from github is relatively painless for Mac/Linux/Ubuntu users, for the windows users it is not that luck. I have to confess that when I used the above code to install these packages it caused a chaos for me. Not only that the package was not installed properly but also some other installed packages were broken!!!

Thiago Silva’s post Installing Slidify on a Windows Machine has provided his advice on how he successfully made a workaround. I will give a step by step guide on top of his blog, which I have successfully installed these 3 packages in window 7 and windows 10 machines.

1.       Download packages zip files

a.       Download slidify zip file from Github 

b.       Download slidifyLibraries zip file from Github 

c.       Download rCharts zip file from Github 

2.       Put zip files into a folder, say, c:/packages

3.       Unzip packages and you will notice that all packages have a “-master” suffix in the folder name. “-master’ will need to be removed as below:


4.       Now we will use the build utility from dvtools package to convert a package source directory into a single bundled file. If set binary = FALSE, this creates a tar.gz package that can be installed on any platform, provided they have a full development environment. Now we will use the below code to build packages:


library(devtools)

build("C:/packages/slidify/", binary=FALSE) # Change C:/packages/ to your folder name

build("C:/packages/slidifyLibraries/", binary=FALSE) # Change C:/packages/ to your folder name

build("C:/packages/rCharts/", binary=FALSE) # Change C:/packages/ to your folder name


5.       Once packages are built successfully, we use the below code or alternatively we can use the RStudio to install these packages:

a.       R Script code:

# Change C:/packages/ to your folder name

install.packages("C:/packages/slidify_0.5.tar.gz", repos = NULL, type="source")

# Change C:/packages/ to your folder name

install.packages("C:/packages/slidifyLibraries_0.3.1.tar.gz", repos = NULL, type="source")

# Change C:/packages/ to your folder name

install.packages("C:/packages/rCharts_0.4.5.tar.gz", repos = NULL, type="source")


b.       Install from RStudio, go to manu: Tools, Install Packages… as below:



This has successfully installed these three packages: sidify, slidifyLibraries, and rCharts in windows environment.

I hope this helps and thanks for reading.



Posted in: R

Tags: , ,

Comments (1) -

Thanks Steven

I still have some issues, because in French, the default location I have contains a space "mes documents". And when I type the command

> build("D:/pack/slidify", binary=FALSE)
"d:/home/mes documents/R/R-3.3.1/bin/x64/R" --no-site-file --no-environ --no-save --no-restore --quiet CMD  \
  build "D:\pack\slidify" --no-resave-data --no-manual

I got a problem since 'd:\home\mes' is not recongnized... what can I do ?

Reply

Add comment