plot a pkggraph object

# S3 method for pkggraph
plot(x, ...)

Arguments

x

plot object generated by neighborhood_graph or make_neighborhood_graph

...

additional arguments (See details)

Details

  • background: "black" or "white". Default is `black`

  • nodeImportance: "in", "out" or "both", in - Node will be considered important(and increased size) if more incoming. out - Node will be considered important if more outgoing. both - Node importance will be calculated on both incoming and outgoing. True for all the nodes. Default is `both`

  • edgeLabel: logical. TRUE if edge label has to be shown. Default is FALSE

See also

neighborhood_graph, make_neighborhood_graph, get_neighborhood

Examples

# NOT RUN {
  pkggraph::init(local = TRUE)
  plot_obj <- pkggraph::neighborhood_graph("hash")
  plot(plot_obj)

  plot_obj <- pkggraph::neighborhood_graph("tidytext")
  plot(plot_obj
       , background     = "white"
       , nodeImportance = "out")
  plot_obj <- pkggraph::neighborhood_graph(c("hash","tokenizers")
                                           , interconnect = FALSE
                                           )
  plot(plot_obj,  background = "white")

# }