Hi experts!
The array ([ 0, 39, 7, 3, 1, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0,
0, 0, 1]) means that in the sistem (graph) are : 4 cluster of size 1, one
cluster of size 3, one cluster of size 7 and one cluste of size 39?
What does means 'zero' (13 times) in the array?
Thans a lot!
José Luis
________________________________
De: Daπid <davidmen...@gmail.com>
Para: Discussion of Numerical Python <numpy-discussion@scipy.org>
Enviado: jueves, 5 de septiembre de 2013 11:06
Asunto: Re: [Numpy-discussion] Stick intersection path algorithm
On 5 September 2013 13:14, Josè Luis Mietta <joseluismie...@yahoo.com.ar> wrote:
2. Using networkx or other tool: how can I obtain the 'clusters size'
distribution (that is: number of clusters of size 'D', for all cluster-sizes)?
This is best asked in their mailing list. A possible way is:
np.bincount([len(i) for i in nx.connected_components(G)])
For example:
np.bincount([len(i) for i in nx.connected_components(nx.erdos_renyi_graph(100,
0.01))])
array([ 0, 39, 7, 3, 1, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0,
0, 1])
_______________________________________________
NumPy-Discussion mailing list
NumPy-Discussion@scipy.org
http://mail.scipy.org/mailman/listinfo/numpy-discussion
_______________________________________________
NumPy-Discussion mailing list
NumPy-Discussion@scipy.org
http://mail.scipy.org/mailman/listinfo/numpy-discussion