'Calculates eigenvector centrality and returns a node => weight dictionary.
Node.weight is updated in the process.
Node.weight is higher for nodes with a lot of (indirect) incoming traffic.'

def eigenvector_centrality(self, normalized=True, reversed=True, rating={}, iterations=100, tolerance=0.0001):

    ec = eigenvector_centrality(self, normalized, reversed, rating, iterations, tolerance)
    ec = nodedict(self, ((self[id], w) for (id, w) in ec.items()))
    for (n, w) in ec.items():
        n._weight = w
    return ec
