Managing a Local R Repository

November 10, 2011

(This article was first published on Jason Bryer » R, and kindly contributed to R-bloggers)

I will be teaching a workshop on R and LaTeX at NEAIR in just under a month. One of the issues I will encounter is a lack of Internet access. I also work with restricted data from NCES which requires the computer to be secured including no network access. As such, I need to manage software from removable media. I have written some functions that will create a local repository, update a local repository, and install packages from the local repository. These are included as part of a new R package irutils that I am developing in support for the workshop and accompanying document/book, Introduction to R an LaTeX for Institutional Research. The irutils is being hosted on Github but the R script file can be retrieved directly here: Here are the functions available (note that the createLocalRepos function can take a long time to run as it will download approximately 2GB of data for source alone):

  • createLocalRepos(local.repos = “~/MyLocalCran”, type=”source”)
  • updateLocalRepos(local.repos = “~/MyLocalCran”, type=”source”)
  • local.available.packages(local.repos = “~/MyLocalCran”, type=”source”)
  • local.install.packages(c(‘devtools’, ‘ggplot2′), local.repos = “~/MyLocalCran”, type=”source”)

To leave a comment for the author, please follow the link and comment on their blog: Jason Bryer » R. offers daily e-mail updates about R news and tutorials on topics such as: Data science, Big Data, R jobs, visualization (ggplot2, Boxplots, maps, animation), programming (RStudio, Sweave, LaTeX, SQL, Eclipse, git, hadoop, Web Scraping) statistics (regression, PCA, time series, trading) and more...

If you got this far, why not subscribe for updates from the site? Choose your flavor: e-mail, twitter, RSS, or facebook...


Comments are closed.

Search R-bloggers


Never miss an update!
Subscribe to R-bloggers to receive
e-mails with the latest R posts.
(You will not see this message again.)

Click here to close (This popup will not appear again)