addWeightedEdge

network.addWeightedEdge(source, target, weight)
Adds an edge with weight “weight” to the network, connecting node “source” with node “target”

Parameters

source: int
Number of the node which is the source of the added connection.
target: int
Number of the node which is the target of the added connection.
weight : float
The weight of the added edge.

Note

For nodes which represent a differential equation, the added connection represent a coupling in the expected direction (source influences target). The command is äquivalent to addEdge (source, target, weightedEdge(weight)).

Example (python-conedy)

import conedy as co

N = co.network()

N.addNode(co.node())
N.addNode()

N.addWeightedEdge(0,1,0.7)

print "Should be 0.7:" + str(N.linkStrength (0,1))

Example (conedy)

network N;


N.addNode(node());
N.addNode();

N.addWeightedEdge(0,1,0.7);


print "Should be 0.7:" + N.linkStrength (0,1);

Table Of Contents

Previous topic

addRandomEdgesDegreeDistribution

Next topic

beeWeb