7
Step 1: Establish input file (*.csv), format as shown in Figure. This is so called edge list. The first column is the id of the source node of edge and as same as the second column. Step 2: Establish new project in Gephi. Step 3: Click data Laboratory to input data.

Step 1: Establish input file (*.csv), format as shown in Figure. This ... · Step í í: Using Drag tools can adjust the position of nodes manually. We can drag and move nodes in

Embed Size (px)

Citation preview

Page 1: Step 1: Establish input file (*.csv), format as shown in Figure. This ... · Step í í: Using Drag tools can adjust the position of nodes manually. We can drag and move nodes in

Step 1: Establish input file (*.csv), format as shown in Figure. This is so called edge list. The first

column is the id of the source node of edge and as same as the second column.

Step 2: Establish new project in Gephi.

Step 3: Click data Laboratory to input data.

Page 2: Step 1: Establish input file (*.csv), format as shown in Figure. This ... · Step í í: Using Drag tools can adjust the position of nodes manually. We can drag and move nodes in

Step 4: Click Import Spreadsheet

Step 5: Choose the *.csv file we created in Step 1 (Note: The separator type should be as same as

the format we use in the *.csv file. If you created the *.csv file by excel, we should choose

“Comma”. Please remember, the *.csv file we use is a Edges table)

Step 6: Import Setting: remember to click the Create missing nodes

Page 3: Step 1: Establish input file (*.csv), format as shown in Figure. This ... · Step í í: Using Drag tools can adjust the position of nodes manually. We can drag and move nodes in

Then we have finished the first part of import. Next, we should find a better way to display this

graph.

Step 7: Change the background color. You can use any color you want, But I think gray is the best.

If you cannot see the setting panel for background color, please click the small triangle.

Page 4: Step 1: Establish input file (*.csv), format as shown in Figure. This ... · Step í í: Using Drag tools can adjust the position of nodes manually. We can drag and move nodes in

Step 8: Run modularity function, choose the Resolution parameter. It depends on your size of

data. We usually use 1.0 or 1.5.

Step 9: Then we change the color of the nodes according to their modularity class. In Appearance

panel, we click the “color”-> “Nodes”-> “attribute”, and then choose “modularity class”. Gephi

will give one color for each class automatically; we can also change them manually. Then click

“apply”

Page 5: Step 1: Establish input file (*.csv), format as shown in Figure. This ... · Step í í: Using Drag tools can adjust the position of nodes manually. We can drag and move nodes in

Step 10: Next, we will apply layout algorithm named ForceAtlas 2 to arrange the nodes in a better

way. We choose “ForceAtlas 2” in Layout panel. Then we need to try different combination of the

parameters. The “scaling” decide the area of the graph and the “gravity” decide the density of

the nodes. Once we decided the parameters, click “Run” to see the results.

Page 6: Step 1: Establish input file (*.csv), format as shown in Figure. This ... · Step í í: Using Drag tools can adjust the position of nodes manually. We can drag and move nodes in

Step 11: Using “Drag” tools can adjust the position of nodes manually. We can drag and move

nodes in same cluster to make them closer.

Step 12: Install JSON plugins to allow Gephi export the graph we created as JSON file. Click

“Tools” -> “Plugins” -> “Available plugins” and choose JSON Exporter.

Restart the Gehpi and Click “File” -> “Export”-> “Graph file” and then choose JSON file to export

our graph.

Page 7: Step 1: Establish input file (*.csv), format as shown in Figure. This ... · Step í í: Using Drag tools can adjust the position of nodes manually. We can drag and move nodes in