p_loaded: Check for Loaded Packages

Description Usage Arguments See Also Examples

View source: R/p_loaded.R

Description

p_loaded - Output is a character string of loaded packages.

p_isloaded - Check if package(s) is loaded.

Usage

1
2
3
p_loaded(..., all = FALSE, char, character.only = FALSE)

p_isloaded(...)

Arguments

all

logical. If TRUE will show all packages including base install; FALSE will show all packages excluding base install packages that install when R loads.

char

Character vector containing packages to load. If you are calling p_loaded from within a function (or just having difficulties calling it using a character vector input) then pass your character vector of packages to load to this parameter directly.

character.only

logical. If TRUE then p_loaded will only accept a single input which is a character vector containing the names of packages to load.

...

Optional package names. Adding package names will check their individual load status.

See Also

.packages, sessionInfo

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
## Not run: 
p_load(lattice, ggplot2)

## End(Not run)
p_loaded()
p_loaded(all=TRUE)
p_loaded(ggplot2, tm, qdap)

p_isloaded(ggplot2)
p_isloaded(ggplot2, dfs, pacman)
## Not run: p
_unload(lattice)

## End(Not run)

trinker/pacman documentation built on May 21, 2020, 6:23 a.m.