In [1]:
import sys
sys.path.append('..')
import socnet as sn
Carregando e visualizando o grafo:
In [2]:
sn.node_size = 3
sn.node_color = (0, 0, 0)
sn.edge_width = 1
sn.edge_color = (192, 192, 192)
sn.node_label_position = 'top center'
g = sn.load_graph('tarefa1.gml')
sn.show_graph(g, nlab=True)
Dependendo do tamanho, o grafo pode demorar um pouco para aparecer.
In [3]:
sn.node_size = 3
sn.node_color = (0, 0, 0)
sn.edge_width = 1
sn.edge_color = (192, 192, 192)
sn.node_label_position = 'top center'
g = sn.load_graph('tarefa2.gml')
sn.show_graph(g, nlab=True)
In [5]:
sn.node_size = 1
sn.node_color = (0, 0, 0)
sn.edge_width = 1
sn.edge_color = (192, 192, 192)
sn.node_label_position = 'top center'
g = sn.load_graph('tarefa5.gml')
sn.show_graph(g, nlab=True)
In [ ]: