G=createlattice(20,3,0); plotlattice(G) ans = 3.0010 102.0009 103.0004 104.0004 105.0004 106.0002 107.0002 108.0002 109.0002 110.0002 111.0002 112.0002 113.0002 114.0002 115.0002 116.0002 117.0002 118.0002 119.0002 120.0002 121.0002 122.0002 123.0002 124.0002 125.0002 126.0002 127.0002 128.0002 129.0002 130.0002 131.0002 132.0002 133.0002 134.0002 135.0002 136.0002 137.0002 138.0002 139.0002 140.0002 141.0002 142.0002 143.0002 144.0002 145.0002 146.0002 147.0002 148.0002 149.0002 150.0002 151.0002 152.0002 153.0002 154.0002 155.0002 156.0002 157.0002 158.0002 159.0002 160.0002 G=createlattice(20,3,0.3); plotlattice(G); p=linspace(0.1,1,20); [L,C]=SmallWorldsEx(20,3,p,3); 1 1 1 2 1 3 2 1 2 2 2 3 3 1 3 2 3 3 4 1 4 2 4 3 5 1 5 2 5 3 6 1 6 2 6 3 7 1 7 2 7 3 8 1 8 2 8 3 9 1 9 2 9 3 10 1 10 2 10 3 11 1 11 2 11 3 12 1 12 2 12 3 13 1 13 2 13 3 14 1 14 2 14 3 15 1 15 2 15 3 16 1 16 2 16 3 17 1 17 2 17 3 18 1 18 2 18 3 19 1 19 2 19 3 20 1 20 2 20 3 whos Name Size Bytes Class C 20x1 160 double array G 20x20 804 double array (sparse) L 20x1 160 double array ans 60x1 480 double array p 1x20 160 double array Grand total is 180 elements using 1764 bytes plot(p,L,'b',p,C,'r') legend('Path Length','Cluster Coefficient',3) exit