PackageDependencies will examine the DESCRIPTION file of a package and return a vector of dependencies.

PackageDependencies(
  x,
  type = c("Depends", "Imports", "Suggests", "Enhances", "LinkingTo")
)

Arguments

x

The name of the packages

type

What sort of dependency are you looking for? Permissible values are "Depends", "Imports", "Suggests", "Enhances" and "LinkingTo"

Examples

if (FALSE) { PackageDependencies("ggplot2", "Depends") }