Exemplo n.º 1
0
 def test_degree_assortativity_multigraph(self):
     r=mixing.degree_assortativity(self.M)
     npt.assert_almost_equal(r,-1.0/7.0,decimal=4)
Exemplo n.º 2
0
 def test_degree_assortativity_undirected(self):
     r=mixing.degree_assortativity(self.P4)
     npt.assert_almost_equal(r,-1.0/2,decimal=4)
Exemplo n.º 3
0
 def test_degree_assortativity_directed(self):
     r=mixing.degree_assortativity(self.D)
     npt.assert_almost_equal(r,-0.57735,decimal=4)
Exemplo n.º 4
0
	def assortativity(self ):
		return degree_assortativity( self._network )