Community detection in Networkx

前端 未结 2 1059
死守一世寂寞
死守一世寂寞 2021-02-07 19:14

I\'m studying about detection communities in networks.

I\'m use igraph and Python

For the optimal number of communities in terms of the modularity measure:

2条回答
  •  清酒与你
    2021-02-07 19:55

    I'm also new to networkx and igraph, I used Gephi, an data visualization tool/software. And it has the same community detection algorithm as the one in networkx you are now using. Specifically, in http://perso.crans.org/aynaud/communities/

    It uses the louvain method described in Fast unfolding of communities in large networks, Vincent D Blondel, Jean-Loup Guillaume, Renaud Lambiotte, Renaud Lefebvre, Journal of Statistical Mechanics: Theory and Experiment 2008(10), P10008 (12pp)

    You can not get desired number of communities, as I know, there're two ways worth to try:

    • Use Gephi. You can use gephi and there's a parameter called resolution that would change the size of the community you get.
    • Use NetworkX. This time, we may not use best_partition(G) any more. But use partition_at_level(dendrogram, level) , I guess this might help.

    Check the source code here for more info.

提交回复
热议问题