This generic function converts several data structures provided by rang into an edgelist of package dependencies.
Usage
convert_edgelist(x, ...)
# S3 method for default
convert_edgelist(x, ...)
# S3 method for ranglet
convert_edgelist(x, ...)
# S3 method for rang
convert_edgelist(x, ...)
Details
the resulting data frame can be converted to an igraph object for plotting and analysis via the function igraph::graph_from_data_frame()
Examples
# \donttest{
if (interactive()) {
graph <- resolve(pkgs = c("openNLP", "LDAvis", "topicmodels", "quanteda"),
snapshot_date = "2020-01-16")
# dependency edgelist of a single package
convert_edgelist(graph$ranglets[[1]])
# full dependency edgelist
convert_edgelist(graph)
}
# }