This is documentation for Mathematica 8, which was
based on an earlier version of the Wolfram Language.
View current documentation (Version 11.1)

CommunityStructurePartition

CommunityStructurePartition[g]
gives the partition of a graph g into communities.
  • The partition groups the vertices into communities, such that there is a higher density of edges within communities than between them.
  • The following option can be given:
WeightedFalsewhether edges with higher weights are preferred during matching
This defines a small graph:
This finds that the network is grouped into two communities:
This defines a small graph:
Needs["GraphUtilities`"]
In[2]:=
Click for copyable input
Out[2]=
This finds that the network is grouped into two communities:
In[3]:=
Click for copyable input
Out[3]=
This specifies a weighted graph:
This plots the graph with edge weights shown:
This finds the community structure, ignoring edge weights:
This finds the community structure, taking into account the edge weights: