Check that packages are installed and install them if not. Optionally: make sure that the most recent version of 'env' packages is installed; load the packages; and/or write a bibliography for the packages.
check_packages(
packages,
update_env = FALSE,
env_deps = FALSE,
lib = FALSE,
bib = FALSE,
...
)Character. Packages to check
Logical. Check for any updates to 'env' packages?
Logical. Call base::library() for each packages?
Logical. Call knitr::write_bib() on packages?
Passed to the bib_file argument of knitr::write_bib().
Unique, sorted vector of package names. Optionally, loads packages and/or writes bibliography.
check_packages(c("dplyr", "envFunc"))
#> [1] "dplyr" "envFunc"