Libraries

Managing Installed Packages in Libraries

In short, a library is just a directory containing installed packages

You can view your current libraries using:

.libPaths()

For the purpose of reproducible environments, a library is the unit we ultimately want to reproduce. R libraries are subject to a few constraints that must be understood to reproduce them:

  1. Only 1 version of each R package can be installed and accessed in a library at a time.
  2. R packages have complex dependency relationships, a working library must have a consistent set of packages that work together
  3. An R library is tied to a specific version of R.
  4. R can search through multiple libraries, and libraries can be shared across projects and users.

Addressing these constraints is the focus of the reproducible strategies.

Back to top