Description Usage Arguments Value Examples
View source: R/filter_component_size.R
Filter a tidygraph object by component size.
1 | filter_component_size(.data, min_size = 0, max_size = Inf)
|
.data |
a tidygraph object (for use in a pipeline) |
min_size, max_size |
minumum and maximum sizes of components to keep (inclussive bounds) |
An object of the same class as .data.
1 2 3 4 5 | gr <- tidygraph::bind_graphs(tidygraph::play_barabasi_albert(3, 2),
tidygraph::play_barabasi_albert(6, 2))
igraph::count_components(gr)
new_gr <- filter_component_size(gr, min_size = 4)
igraph::count_components(new_gr)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.