cdlib.algorithms.mcode¶

mcode
(g_original: object, weights: str = None, weight_threshold: float = 0.2) → cdlib.classes.node_clustering.NodeClustering¶ MCODE is the earliest seedgrowth method for predicting protein complexes from PPI networks. MCODE works in two steps:
 vertex weighting, and
 molecular complex prediction.
In the vertex weighting step, the weight of a vertex v in the PPI network is calculated from the highest kcore of v’s neighborhood, including v. The kcore of a graph is a subgraph where every node is of degree k or greater; the highest kcore is simply the kcore with the highest value of k. The weight of v is deﬁned as this maximum k times the density of the corresponding kcore.
Supported Graph Types
Undirected Directed Weighted Yes No Yes Parameters:  g_original – a networkx/igraph object
 weights – label used for the edge weights. Default, None.
 weight_threshold – Threshold for similarity weighs
Returns: NodeClustering object
Example: >>> from cdlib import algorithms >>> import networkx as nx >>> G = nx.karate_club_graph() >>> coms = algorithms.mcode(G)
References: Bader, G.D., Hogue, C.W. 2003. An automated method for ﬁnding molecular complexes in large protein interaction networks. BMC Bioinformatics 4, 2.
Note
Reference Implementation: https://github.com/trueprice/pythongraphclustering