I would like to be able to see relationships between two nodes (or more).
Let's say I have those two paths: 1-2-4-5-7-8 1-3-4-6-7-8
From this we can see that nodes 2&5 are "linked together" and so are 3&6.
But if i just add those paths to a graph I end up with something like that:
G = nx.DiGraph()
nx.add_path(G, [1,2,4,5,7,8])
nx.add_path(G, [1,3,4,6,7,8])
nx.draw(G, with_labels=True)
plt.show()
Yet it doesn't show the relations between 2&5 and between 3&6 and it seems like I can have the combination 2&6 and 3&5 even though they don't exist in my initial paths.
Is there anyway to show this ?
I am coding this python and using the libraries networkx to build the graph and pygraphviz for the visualization/rendering.

