You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@s2graph.apache.org by "Daewon Jeong (JIRA)" <ji...@apache.org> on 2018/06/08 06:30:00 UTC

[jira] [Created] (S2GRAPH-219) Added query that includes all vertices and associated edges for GraphVisualize.

Daewon Jeong created S2GRAPH-219:
------------------------------------

             Summary: Added query that includes all vertices and associated edges for GraphVisualize.
                 Key: S2GRAPH-219
                 URL: https://issues.apache.org/jira/browse/S2GRAPH-219
             Project: S2Graph
          Issue Type: Improvement
          Components: s2graphql
            Reporter: Daewon Jeong


h1. Supports result format for GraphVisualize.

The query result of S2Graph is suitable for checking connected data.

However, such as [sigma.js|http://sigmajs.org/], the Grpah drawing tool must process the results to use it.

Connecting all vertices and edges is a complex and tedious task.

Therefore, supports the result format which is easy to use in Graph Tools like the [sigma.js|http://sigmajs.org/].

[sigma.js|http://sigmajs.org/] requires the following form.

{code:json}
{
  "nodes": [
    {
      "id": "n0",
      "label": "A node",
      "x": 0,
      "y": 0,
      "size": 3
    },
    {
      "id": "n1",
      "label": "Another node",
      "x": 3,
      "y": 1,
      "size": 2
    },
    {
      "id": "n2",
      "label": "And a last one",
      "x": 1,
      "y": 3,
      "size": 1
    }
  ],
  "edges": [
    {
      "id": "e0",
      "source": "n0",
      "target": "n1"
    },
    {
      "id": "e1",
      "source": "n1",
      "target": "n2"
    },
    {
      "id": "e2",
      "source": "n2",
      "target": "n0"
    }
  ]
}
{code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)