#NEWLINE# def test_krackhardt_kite_graph_normalized( self ) : #NEWLINE# #INDENT# 'Betweenness centrality: Krackhardt kite graph normalized' #NEWLINE# G = nx . krackhardt_kite_graph ( ) #NEWLINE# b_answer = { #NEWLINE# #INDENT# 0 : 0.023 , #NEWLINE# 1 : 0.023 , #NEWLINE# 2 : 0.0 , #NEWLINE# 3 : 0.102 , #NEWLINE# 4 : 0.0 , #NEWLINE# 5 : 0.231 , #NEWLINE# 6 : 0.231 , #NEWLINE# 7 : 0.389 , #NEWLINE# 8 : 0.222 , #NEWLINE# 9 : 0.0 , #NEWLINE# #UNINDENT# } #NEWLINE# b = nx . betweenness_centrality ( b , weight = None , normalized = True ) #NEWLINE# for n in sorted ( G ) : #NEWLINE# #INDENT# assert_almost_equal ( b [ n ] , b_answer [ n ] , places = 3 )