| community_fluid | R Documentation |
Simulates fluid dynamics where communities compete for nodes. Requires specifying the number of communities.
community_fluid(x, no.of.communities, ...)
com_fl(x, no.of.communities, ...)
x |
Network input |
no.of.communities |
Number of communities to detect. Required. |
... |
Additional arguments passed to |
A cograph_communities object
A cograph_communities object. See detect_communities.
Pares, F., Gasulla, D.G., Vilalta, A., Moreno, J., Ayguade, E., Labarta, J., Cortes, U., & Suzumura, T. (2018). Fluid communities: A competitive, scalable and diverse community detection algorithm. Studies in Computational Intelligence, 689, 229-240.
if (requireNamespace("igraph", quietly = TRUE)) {
g <- igraph::make_graph("Zachary")
# Detect exactly 2 communities
comm <- community_fluid(g, no.of.communities = 2)
}
m <- matrix(runif(25), 5, 5); diag(m) <- 0
net <- as_cograph(m)
com_fl(net, no.of.communities = 2)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.