Nutshell
Make  R scripts reproducible by replacing library(pkg) with groundhog.library(pkg,date)

  • groundhog.library() loads a package & its dependencies, as available on chosen date.
  • Packages get automatically installed if needed.
  • Installation keeps, rather than replaces, existing other versions of that package.
  • If you want to discontinue using groundhog, simply:  groundhog.library(pkg,date).

 

Example:
install.packages("groundhog")
library("groundhog")
groundhog.library("rio", "2020-03-01")

#Since groundhog_1.2.0, may install set of packages in one line
pkgs <- c("rio","metafor")
groundhog.library(pkgs, "2020-03-01")

 

 

 

 



2 comments

Comments are closed.