Thanks a lot Dan and Fidel :)
I was able to add edges by using a simple for loop with
myGraph.add_edge(protein, lGene)...I now need to calculate the
clustering coefficient for all nodes in my network. I found out that
by following the example below i could compute the number of triangles
in the network.But if anyone could please clarify and elaborate a bit
more on it:
>>> G=nx.complete_graph(5)
>>> print nx.triangles(G,0)
6
>>> print nx.triangles(G,with_labels=True)
{0: 6, 1: 6, 2: 6, 3: 6, 4: 6}
>>> print nx.triangles(G,(0,1))
[6, 6]
in the first line, do I need to pass the total no. of nodes in my
network? What is the significance of '0' in the second line? so that
it starts from the very beginning?
and the fourth line i assume returns true whenever it finds a trianlge
in the graph right?
Moreover, I need to calculate the Pearson Correlation Coefficient in
order to get the relatedness of the biological network. Is there a way
to do that in networkx?
Thanks in adv. !
> > group/networkx-discuss?hl=.- Hide quoted text -
>
> - Show quoted text -