Package Information

Share:

Description

Provides the information from for a package from the NAMESPACE. Information may include: title, version, author, maintainer, description, depends, imports, suggests

Usage

1
2
3
p_information(package = "base", ..., fields = NULL)

p_info(package = "base", ..., fields = NULL)

Arguments

package

Name of the package to grab information for. Default is "base".

fields

A character vector giving the tags of fields to return (for use inside of functions rather than ...).

...

Names of fields (see fields argument) to extract.

Value

Returns a list of fields.

Note

Note that the output from p_information (when no fields are passed) prints pretty but is actually an accessible list (use names(p_info()) test).

See Also

packageDescription, p_information

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
p_information()
p_info()
names(p_info())
p_info()[names(p_info())]
p_info(pacman)
p_info(pacman, Author)
p_info(pacman, BugReports, URL)
p_info(pacman, fields = "Version")
## Not run: 
p_extract(p_info(ggplot2, "Depends"))
p_extract(p_info(ggplot2, "Imports"))
lapply(p_info(ggplot2, "Imports", "Depends", "Suggests"), p_extract)

## End(Not run)

Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.