Get parent dependency for a package

parent_dependency(package, fields = NULL, online = FALSE)

Arguments

package

Package name.

fields

Which fields in DESCRIPTION? Values should be in Depends, Imports, LinkingTo, Suggests and Enhances. The value can also be set to strong or weak.

online

Whether use the newest package database directly from CRAN/Bioconductor or the pre-computated package database? The version of the pre-computated package database can be set via pkgndep_opt$heaviness_db_version.

Value

A data frame with parent packages as well as their heaviness on pacakge. If snapshot is set to FALSE, heaviness on child packages is set to NA.

Examples

# \dontrun{
parent_dependency("ComplexHeatmap")
#>            parents       children dep_fields heaviness
#> 1          methods ComplexHeatmap    Depends         0
#> 2             grid ComplexHeatmap    Depends         0
#> 3         graphics ComplexHeatmap    Depends         0
#> 4            stats ComplexHeatmap    Depends         0
#> 5        grDevices ComplexHeatmap    Depends         0
#> 6         circlize ComplexHeatmap    Imports         2
#> 7       GetoptLong ComplexHeatmap    Imports         3
#> 8       colorspace ComplexHeatmap    Imports         0
#> 9             clue ComplexHeatmap    Imports         2
#> 10    RColorBrewer ComplexHeatmap    Imports         1
#> 11   GlobalOptions ComplexHeatmap    Imports         0
#> 12             png ComplexHeatmap    Imports         1
#> 13          digest ComplexHeatmap    Imports         1
#> 14         IRanges ComplexHeatmap    Imports         4
#> 15     matrixStats ComplexHeatmap    Imports         1
#> 16         foreach ComplexHeatmap    Imports         0
#> 17      doParallel ComplexHeatmap    Imports         2
#> 18       codetools ComplexHeatmap    Imports         0
#> 19        testthat ComplexHeatmap   Suggests        30
#> 20           knitr ComplexHeatmap   Suggests        10
#> 21        markdown ComplexHeatmap   Suggests         5
#> 22        dendsort ComplexHeatmap   Suggests         1
#> 23            jpeg ComplexHeatmap   Suggests         1
#> 24            tiff ComplexHeatmap   Suggests         1
#> 25     fastcluster ComplexHeatmap   Suggests         1
#> 26 EnrichedHeatmap ComplexHeatmap   Suggests        13
#> 27      dendextend ComplexHeatmap   Suggests        31
#> 28        grImport ComplexHeatmap   Suggests         2
#> 29       grImport2 ComplexHeatmap   Suggests         4
#> 30            glue ComplexHeatmap   Suggests         1
#> 31   GenomicRanges ComplexHeatmap   Suggests         8
#> 32        gridtext ComplexHeatmap   Suggests        15
#> 33        pheatmap ComplexHeatmap   Suggests        12
#> 34    gridGraphics ComplexHeatmap   Suggests         1
#> 35          gplots ComplexHeatmap   Suggests         5
#> 36       rmarkdown ComplexHeatmap   Suggests        25
#> 37           Cairo ComplexHeatmap   Suggests         1
# }