igraph-help
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [igraph] Qualifying individual communities


From: Gábor Csárdi
Subject: Re: [igraph] Qualifying individual communities
Date: Tue, 4 Feb 2014 16:30:37 -0500

http://stackoverflow.com/questions/21559915/r-igraph-testing-the-quality-of-multiple-communities

Cross posting is considered to be "not nice" by some, and these people might be less likely to answer your question. FYI.

Gabor


On Tue, Feb 4, 2014 at 3:37 PM, A. Gerow <address@hidden> wrote:
Greetings -

After computing a set of communities, using a multi-cut algorithm like infomap.community(), I understand it computes the modularity of the best (highest modularity) community. How can I calculate this for individual communities (ie. not just the best)?

In my example, I'd like to run something like this:

g <- graph.from.somewhere
comms <- infomap.community(g,modularity=T,nb.trials=30)
solution_modularity <- modularity(comms)

# The biggest communities:
for (comm in names(sort(sizes(comms),decreasing=T)[0:20])) {  
  g2 <- induced.subgraph(g, which(membership(comms) == comm))

  ### Need to compute the modularity of comm or g2 here ###
   
Any ideas?
    - Aaron

--
A. Gerow
Knowledge Lab | Computation Institute
University of Chicago
5735 South Ellis Avenue
Chicago, IL 60637 - USA

_______________________________________________
igraph-help mailing list
address@hidden
https://lists.nongnu.org/mailman/listinfo/igraph-help



reply via email to

[Prev in Thread] Current Thread [Next in Thread]