Install packages from Bioconductor, CRAN, or a Git remote
install(
pkgs,
configureArgs = getOption("configure.args"),
configureVars = getOption("configure.vars"),
dependencies = TRUE,
lib = .libPaths()[[1L]],
type = getOption("pkgType"),
reinstall = TRUE
)
Arguments
| pkgs |
character.
Package names to install.
By default, strings are passed to BiocManager::install().
Special cases:
Package tarball files and remote URLs (i.e. from CRAN or Bioconductor)
are supported.
Strings matching "USER/REPO" are treated as GitHub repositories,
and installed using remotes::install_github().
Strings ending with ".git" are treated as Git repositories, and
installed using remotes::install_git().
|
| configureArgs, configureVars |
character or named list.
Used only for source installs. If a character vector with no names is
supplied, the elements are concatenated into a single string (separated by
a space) and used as the value for the --configure-args or
configure-vars flag in the call to R CMD INSTALL. If the character
vector has names, these are assumed to identify values for
--configure-args or --configure-vars for individual packages. This
allows one to specify settings for an entire collection of packages which
will be used if any of those packages are to be installed.
A named list can be used also to the same effect, and that allows
multi-element character strings for each package which are concatenated to
a single string to be used as the value for --configure-args and/or
--configure-vars. |
| dependencies |
logical(1), character, or NA.
|
| lib |
character.
Destination library directory paths.
Defaults to the first element of .libPaths().
|
| type |
character(1).
Type of package to download and install. "source" is recommended by
default, but "binary" can be used on macOS or Windows to install
pre-built binaries from CRAN or Bioconductor.
Note that installing from source requires the correct GCC and GNU Fortran
binaries to be installed, and Apple LLVM/Clang compilers should not be used
on macOS. Refer to macOS development tools for details. |
| reinstall |
logical(1).
Force reinstallation of any existing packages.
|
Value
Invisible character.
Package names defined in the pkgs argument.
Note
Updated 2020-12-03.
Examples
## > install(pkgs = c("DESeq2", "edgeR"))