Skip to content

Commit ce807cb

Browse files
committed
Graph Algos
1 parent fbf0b47 commit ce807cb

File tree

3 files changed

+42
-11
lines changed

3 files changed

+42
-11
lines changed

documentation/panama-papers-examples.html

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -424,7 +424,7 @@ <h3>Search for Officer nodes by name</h3>
424424
<div class="listingblock">
425425
<div class="content">
426426
<pre mode="cypher" class="highlight pre-scrollable code runnable standalone-example ng-binding"><code
427-
class="cypher language-cypher">:param officer:"<span value-key="officer">A Name</span>"</code></pre>
427+
class="cypher language-cypher">:param officer=>"<span value-key="officer">A Name</span>"</code></pre>
428428
</div>
429429
</div>
430430
<div class="listingblock">
@@ -494,7 +494,7 @@ <h3>Find who is behind an Entity and the roles that they play</h3>
494494
<div class="listingblock">
495495
<div class="content">
496496
<pre mode="cypher" class="highlight pre-scrollable code runnable standalone-example ng-binding">
497-
<code class="cypher language-cypher">:param entity:"<span value-key="entity">An Entity</span>"</code></pre>
497+
<code class="cypher language-cypher">:param entity=>"<span value-key="entity">An Entity</span>"</code></pre>
498498
</div>
499499
</div>
500500
<div class="listingblock">
@@ -720,7 +720,7 @@ <h3>Most popular offshore jurisdictions for people with addresses in a certain c
720720
<form>
721721
<div class="node">
722722
<div class="form-group">
723-
<label>City:</label> <input value-for="state" value="London" class="form-control">
723+
<label>City:</label> <input value-for="city" value="London" class="form-control">
724724
<label>State/country:</label> <input value-for="state" value="United Kingdom" class="form-control">
725725
</div>
726726
</div>
@@ -983,6 +983,17 @@ <h3>Full text search with graph patterns</h3>
983983
<h3>Graph Analytics</h3>
984984
<br/>
985985
<div>
986+
<div class="paragraph">
987+
<p>We start by projecting the graph into an in-memory represenation suitable for heavy computation</p>
988+
</div>
989+
<div class="listingblock">
990+
<div class="content">
991+
<pre mode="cypher" class="highlight pre-scrollable code runnable standalone-example ng-binding"><code
992+
class="cypher language-cypher">call gds.graph.project("offshoreleaks","*","*");
993+
</code></pre>
994+
</div>
995+
</div>
996+
986997
<div class="paragraph">
987998
<p>PageRank is an algorithm used for instance by Google to rank websites in their search engine
988999
results.
@@ -996,7 +1007,7 @@ <h3>Graph Analytics</h3>
9961007
<div class="listingblock">
9971008
<div class="content">
9981009
<pre mode="cypher" class="highlight pre-scrollable code runnable standalone-example ng-binding"><code
999-
class="cypher language-cypher">CALL gds.pageRank.stream({nodeProjection:'*',relationshipProjection:'*'}) YIELD nodeId, score
1010+
class="cypher language-cypher">CALL gds.pageRank.stream("offshoreleaks") YIELD nodeId, score
10001011
WITH gds.util.asNode(nodeId) as node, score
10011012
WHERE node:Entity AND node.sourceID = "Panama Papers"
10021013
RETURN node.name AS entity, score
@@ -1014,7 +1025,7 @@ <h3>Graph Analytics</h3>
10141025
<div class="listingblock">
10151026
<div class="content">
10161027
<pre mode="cypher" class="highlight pre-scrollable code runnable standalone-example ng-binding"><code
1017-
class="cypher language-cypher">CALL gds.pageRank.stream({nodeProjection:'*',relationshipProjection:'*'}) YIELD nodeId, score
1028+
class="cypher language-cypher">CALL gds.pageRank.stream("offshoreleaks") YIELD nodeId, score
10181029
WITH gds.util.asNode(nodeId) as node, score
10191030
WHERE node:Address AND node.sourceID = "Panama Papers"
10201031
WITH * ORDER BY score DESC LIMIT 10

documentation/pandora-papers-examples.html

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -709,7 +709,7 @@ <h3>Most popular offshore jurisdictions for people with addresses in a certain c
709709
<form>
710710
<div class="node">
711711
<div class="form-group">
712-
<label>City:</label> <input value-for="state" value="London" class="form-control">
712+
<label>City:</label> <input value-for="city" value="London" class="form-control">
713713
<label>State/country:</label> <input value-for="state" value="United Kingdom" class="form-control">
714714
</div>
715715
</div>
@@ -963,6 +963,16 @@ <h3>Full text search with graph patterns</h3>
963963
<h3>Graph Analytics</h3>
964964
<br/>
965965
<div>
966+
<div class="paragraph">
967+
<p>We start by projecting the graph into an in-memory represenation suitable for heavy computation</p>
968+
</div>
969+
<div class="listingblock">
970+
<div class="content">
971+
<pre mode="cypher" class="highlight pre-scrollable code runnable standalone-example ng-binding"><code
972+
class="cypher language-cypher">call gds.graph.project("offshoreleaks","*","*");
973+
</code></pre>
974+
</div>
975+
</div>
966976
<div class="paragraph">
967977
<p>PageRank is an algorithm used for instance by Google to rank websites in their search engine
968978
results.
@@ -976,7 +986,7 @@ <h3>Graph Analytics</h3>
976986
<div class="listingblock">
977987
<div class="content">
978988
<pre mode="cypher" class="highlight pre-scrollable code runnable standalone-example ng-binding"><code
979-
class="cypher language-cypher">CALL gds.pageRank.stream({nodeProjection:'*',relationshipProjection:'*'}) YIELD nodeId, score
989+
class="cypher language-cypher">CALL gds.pageRank.stream("offshoreleaks") YIELD nodeId, score
980990
WITH gds.util.asNode(nodeId) as node, score
981991
WHERE node:Entity
982992
RETURN node.name AS entity, score
@@ -994,7 +1004,7 @@ <h3>Graph Analytics</h3>
9941004
<div class="listingblock">
9951005
<div class="content">
9961006
<pre mode="cypher" class="highlight pre-scrollable code runnable standalone-example ng-binding"><code
997-
class="cypher language-cypher">CALL gds.pageRank.stream({nodeProjection:'*',relationshipProjection:'*'}) YIELD nodeId, score
1007+
class="cypher language-cypher">CALL gds.pageRank.stream("offshoreleaks") YIELD nodeId, score
9981008
WITH gds.util.asNode(nodeId) as node, score
9991009
WHERE node:Address
10001010
WITH * ORDER BY score DESC LIMIT 10

documentation/paradise-papers-examples.html

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -716,7 +716,7 @@ <h3>Most popular offshore jurisdictions for people with addresses in a certain c
716716
<form>
717717
<div class="node">
718718
<div class="form-group">
719-
<label>City:</label> <input value-for="state" value="London" class="form-control">
719+
<label>City:</label> <input value-for="city" value="London" class="form-control">
720720
<label>State/country:</label> <input value-for="state" value="United Kingdom" class="form-control">
721721
</div>
722722
</div>
@@ -975,6 +975,16 @@ <h3>Full text search with graph patterns</h3>
975975
<h3>Graph Analytics</h3>
976976
<br/>
977977
<div>
978+
<div class="paragraph">
979+
<p>We start by projecting the graph into an in-memory represenation suitable for heavy computation</p>
980+
</div>
981+
<div class="listingblock">
982+
<div class="content">
983+
<pre mode="cypher" class="highlight pre-scrollable code runnable standalone-example ng-binding"><code
984+
class="cypher language-cypher">call gds.graph.project("offshoreleaks","*","*");
985+
</code></pre>
986+
</div>
987+
</div>
978988
<div class="paragraph">
979989
<p>PageRank is an algorithm used for instance by Google to rank websites in their search engine
980990
results.
@@ -988,7 +998,7 @@ <h3>Graph Analytics</h3>
988998
<div class="listingblock">
989999
<div class="content">
9901000
<pre mode="cypher" class="highlight pre-scrollable code runnable standalone-example ng-binding"><code
991-
class="cypher language-cypher">CALL gds.pageRank.stream({nodeProjection:'*',relationshipProjection:'*'}) YIELD nodeId, score
1001+
class="cypher language-cypher">CALL gds.pageRank.stream("offshoreleaks") YIELD nodeId, score
9921002
WITH gds.util.asNode(nodeId) as node, score
9931003
WHERE node:Entity AND node.sourceID STARTS WITH "Paradise Papers"
9941004
RETURN node.name AS entity, score
@@ -1006,7 +1016,7 @@ <h3>Graph Analytics</h3>
10061016
<div class="listingblock">
10071017
<div class="content">
10081018
<pre mode="cypher" class="highlight pre-scrollable code runnable standalone-example ng-binding"><code
1009-
class="cypher language-cypher">CALL gds.pageRank.stream({nodeProjection:'*',relationshipProjection:'*'}) YIELD nodeId, score
1019+
class="cypher language-cypher">CALL gds.pageRank.stream("offshoreleaks") YIELD nodeId, score
10101020
WITH gds.util.asNode(nodeId) as node, score
10111021
WHERE node:Address AND node.sourceID STARTS WITH "Paradise Papers"
10121022
WITH * ORDER BY score DESC LIMIT 10

0 commit comments

Comments
 (0)