def degree_assortativity_coefficient(G, x='out', y='in', weight=None, nodes=None):
 M = degree_mixing_matrix(G, x=x, y=y, nodes=nodes, weight=weight)
 return numeric_ac(M)

def degree_assortativity_coefficient ( G , x = 'out' , y = 'in' , weight = None , nodes = None ) : M = degree_mixing_matrix ( G , x = x , y = y , nodes = nodes , weight = weight ) return numeric_ac ( M )
compute degree assortativity of graph .