Installs specified versions of R packages
hosted on CRAN and provides functions to list available versions and the
versions of currently installed packages. These tools can be used to help
make R projects and packages more reproducible.
versions fits in the narrow gap between the devtools
install_version function and the checkpoint package.
devtools::install_version installs a stated package version from
source files stored on the CRAN archives. However CRAN does not store
binary versions of packages so Windows users need to have RTools installed
and Windows and OSX users get longer installation times.
checkpoint uses the Revolution Analytics MRAN server to
install packages (from source or binary) as they were available on
a given date. It also provides a helpful interface to detect the packages
in use in a directory and install all of those packages for a given date.
checkpoint doesn't provide install.packages-like functionality
however, and that's what versions aims to do, by querying MRAN.
As MRAN only goes back to 2014-09-17, versions can't install packages
from before this date.
The available functions are:
available.versions
install.versions
install.dates
installed.versions
The URL for MRAN may change from time to time. As of versions
0.4, the URL is https://cran.microsoft.com/snapshot, and this is what
the package uses. If the MRAN server URL changes before versions can
be updated, users can point versions to the new URL via the option
'versions.mran'. Ie. options(versions.mran = "<some/new/url>")
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16  | ## Not run: 
# list the available versions of checkpoint
available.versions('checkpoint')
# install a specific version
install.versions('checkpoint', '0.3.9')
# check the installed version
installed.versions('versions')
# install checkpoint as of a specific date
install.dates('checkpoint', '2014-12-25')
## End(Not run)
 | 
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.