I'm trying to find a fixed number of communities in a fully connected graph with weighted edges.
How to do community detection in a weighted social network/graph? suggests the use of iGraph's fastgreeedy function for community detection.
I have a graph with vertices as people and edge weights as the similarity between the vertices.
I'm new to graph theory so I'm not sure if this is correct but I'm in a way trying to achieve max-sum k-clustering.
Best Answer
This post discusses two possible igraph community functions that allow you to set a specific number of communities:
https://stackoverflow.com/a/38899957/1333650
Quoting from Jim Leach:
However, unless there is a specific network metric that you want to inform the formation of your communities, you might just want to use a normal k-means clustering algorithm directly on the weight adjacency matrix, something like this:
https://stat.ethz.ch/R-manual/R-devel/library/stats/html/kmeans.html