powered by
A utility to check whether CRAN / GitHub / Bioconductor packages are installed, with optional auto-installation via inst_pkg().
inst_pkg()
check_pkg( pkg = NULL, source = c("CRAN", "GitHub", "Bioconductor"), auto_install = TRUE, ... )
A tibble with columns: package, name, installed, source.
package
name
installed
source
Character vector of package names or GitHub repos (e.g., "r-lib/devtools").
Package source: one of "CRAN", "GitHub", "Bioconductor". Case-insensitive.
Logical. If TRUE (default), install missing packages automatically.
Additional arguments passed to inst_pkg().
check_pkg("ggplot2", source = "CRAN") check_pkg("r-lib/devtools", source = "GitHub", auto_install = FALSE)
Run the code above in your browser using DataLab