Example 2 of Pajek-XXL usage
In the second example Pajek-XXL will be used to get interesting result in a large network in two steps:
first extracting k-neighbourhood of selected vertex and then computing k-core of it.
- Load dic28.net to Pajek-XXL.
- Compute k-neighbours of selected vertex (e.g. vertex with number 9799 which corresponds to 'write'):
Run Network / Create Partition / k-Neighbours/All and enter 9799 in the first and leave value 0 in the second dialog box.
After obtaining Partition as a result, use Partition / Info to get:
Cluster Freq Freq% Valid% CumFreq CumFreq% CumValid% Represent
------------------------------------------------------------------
0 1 0.0019 0.0040 1 0.0019 0.0040 9799
1 9 0.0171 0.0362 10 0.0190 0.0403 2293
2 51 0.0969 0.2054 61 0.1159 0.2457 258
3 324 0.6154 1.3048 385 0.7312 1.5505 43
4 1421 2.6989 5.7227 1806 3.4301 7.2732 6
5 3648 6.9285 14.6913 5454 10.3586 21.9645 2
...
- Extract the 2-neighbourhood of selected vertex by using
Operations / Network+Partition / Extract SubNetwork and entering 0-2 in the dialog box.
As the result you will get a new network with 61 vertices and corresponding id's:
(vertex 1 is v258,..., vertex 61 is v36290).
- Compute k-cores on the network with 61 vertices by running
Network / Create Partition / k-Core / All
After that Partition / Info gives us:
Cluster Freq Freq% CumFreq CumFreq% Representative
---------------------------------------------------------------
1 3 4.9180 3 4.9180 v9751
2 17 27.8689 20 32.7869 v2222
3 9 14.7541 29 47.5410 v3091
4 11 18.0328 40 65.5738 v339
5 6 9.8361 46 75.4098 v9689
6 6 9.8361 52 85.2459 v258
8 9 14.7541 61 100.0000 v2264
---------------------------------------------------------------
Sum 61 100.0000
- Now let us extract only the densest part (8-core) from the network.
To obtain it run Operations / Network + Partition / Extract SubNetwork and enter 8 in the dialog box.
The result is a network with 9 vertices and the following id's:
1. 2264
2. 2269
3. 2274
4. 2279
5. 2281
6. 2288
7. 2291
8. 2293
9. 2295
Now you can use Option 1 or Option 2 to bring extracted subnetwork from Pajek-XXL to Pajek.
Option 1:
You can call program Pajek directly from Pajek-XXL with the extracted network where labels are replaced with the right ones (stored in the file).
For that purpose use the command:
Tools / Pajek / Send Network to Pajek / +Add Vertex Labels from File(s).
|
Option 2:
If you for some reason do not want to call Pajek directly from Pajek-XXL (maybe not enough memory is available to have Pajek-XXL and Pajek running at the same time),
you can save the obtained subnetwork first, later call Pajek, load the network
and replace labels with the real ones. Sequence of steps to do this is e the following one:
- By saving the network in a usual way to a NET file, you get network with labels v2264,...v2296.
Be sure that Options / Read-Write / Save VertexIDs as Vertex Labels is checked before saving (otherwise definition of vertices is not written to a NET file).
*Vertices 9
1 v2264
2 v2269
3 v2274
4 v2279
5 v2281
6 v2288
7 v2291
8 v2293
9 v2295
*Edges
1 2 1
1 3 1
1 4 1
...
- Now run 'ordinary' Pajek and load the saved network with 9 vertices.
You can draw the network and obtain the layout with labels
v2264,...v2295:
- Run Network / Create New Network / Transform / Add / Vertex Labels / from File(s) and select file with labels (dic28.net).
Finally, the obtained network has the original labels:
rice, ride, rife,...rive.
If you draw this network you get:
|
By saving the obtained network in Pajek in a usual way to a NET file, you get a NET file with additional information (labels, coordinates):
*Vertices 9
1 "rice" 0.0294 0.5064 0.5000
2 "ride" 0.1230 0.2493 0.5000
3 "rife" 0.3600 0.1125 0.5000
4 "rile" 0.6294 0.1600 0.5000
5 "rime" 0.8053 0.3696 0.5000
6 "ripe" 0.8053 0.6432 0.5000
7 "rise" 0.6294 0.8528 0.5000
8 "rite" 0.3600 0.9003 0.5000
9 "rive" 0.1230 0.7635 0.5000
*Edges
1 2 1
1 3 1
1 4 1
...
Back to Example 1
About Pajek-XXL; Download Pajek-XXL.
|