Edge-betweenness community detection
An alternative community detection method is edge-betweenness. In this exercise you will repeat the community detection of the karate club using this method and compare the results visually to the fast-greedy method.
Questo esercizio fa parte del corso
Network Analysis in R
Istruzioni dell'esercizio
- Use the function
edge.betweenness.community()on the graph objectgto create the communityigraphobjectgc. - Calculate the size and number of communities by using the function
sizeson the communityigraphobject. - Plot each community plot next to each other using
par(). The first plot should include the community objectkcfrom the previous exercise. The second plot should include the community objectgc.
Esercizio pratico interattivo
Prova a risolvere questo esercizio completando il codice di esempio.
# Perform edge-betweenness community detection on network graph
gc = ___(g)
# Determine sizes of each community
___(___)
# Plot community networks determined by fast-greedy and edge-betweenness methods side-by-side
par(mfrow = c(1, 2))
plot(___, g)
plot(___, g)