Finding out the shortest path in the graph
Finding the shortest path in a graph is one of the problems that is widely encountered in many different situations across many different domains. This is one of the fundamental problems in graph theory. It has applications in domains such as computer networks, inventory optimization, flow networks, and so on. In this recipe, we will learn how to compute and visualize the shortest path in a graph in Gephi.
Getting ready
Load a pre-existing network in which you would like to find the shortest path, such as Les Misérables, or create one.
How to do it…
To compute and visualize the shortest path for a pair of nodes in a network, follow these steps:
Click on the button with an airplane symbol on it in the vertically placed left-hand side toolbar in the Graph panel. When placed over this button, the mouse pointer displays a descriptor textbox that reads Shortest Path.
Now click on the source node in the graph from where the path should start.
Select the target...