Open user1246638 opened 5 years ago
line 5 in my example code should be
for edge in nwk.edges:
The workaround that I tried is to create a directed network, and then normalize for each node its outgoing edges. This also fails because of numeric issues: weights sum to 1.00000000000002 or 0.99999999998.
Example
The problem is that the probabilities are not weighted, because weights are not normalized. The thing is that in an udirected network they cannot be normalized, for example, take graph A-B-C because A and C have only one link, weights have to be 1 on both AB and BC edges. But then weights around B are not normalized.