Error - Unhandled promise rejection while using Neovis.js

Hi Payal,

I did not see your post for a long time. Probably you have found out the solution by now. If not, please check the reply to Sharath in the below mail trail.

For the color - There are 5-7 basic colors for the nodes that paint the nodes. And when i rendered the neovis.js counterpart of Neo4j , i got plain grey colored nodes. SO i researched and got this query to run -


// -----------------  Color Cluster Query  ----------------------

CALL algo.labelPropagation(null,null,'OUTGOING',{write:true, partitionProperty:'partition', weightProperty:'count'})

[2] Also mention the key-value pairs of labels and relationships like -


  var config = {
      container_id: vizIdSingular,
      server_url: this.url,
      server_user: this.user,
      server_password: this.password,
      labels: {
   
        "Organization": {
          "thickness": "weight",
          "caption": "value",
          "size": "pagerank",
          "community": "community",
          "sizeCypher": "MATCH (n) WHERE id(n) = {id} MATCH (n)-[r]-() RETURN sum(r.weight) AS c"
        },
        "Parameter": {
          "thickness": "weight",
          "caption": "value",
          "size": "pagerank",
          "community": "community",
          "sizeCypher": "MATCH (n) WHERE id(n) = {id} MATCH (n)-[r]-() RETURN sum(r.weight) AS c"
        },
        "Department": {
          "thickness": "weight",
          "caption": "value",
          "size": "pagerank",
          "community": "community",
          "sizeCypher": "MATCH (n) WHERE id(n) = {id} MATCH (n)-[r]-() RETURN sum(r.weight) AS c"
        },

     
      
        "API": {
          "thickness": "weight",
          "caption": "value",
          "size": "pagerank",
          "community": "community",

        },

        "System": {
          "thickness": "weight",
          "caption": "value",
          "size": "pagerank",
          "community": "community",
        },
     
        "Method": {
          "thickness": "weight",
          "caption": "value",
          "size": "pagerank",
          "community": "community",
        },

      },
      relationships: {
        "Parameter": {
          "thickness": "weight",
          "caption": true,
          "community": "community",
          "color": 'red'
        },
        "Method": {
          "thickness": "weight",
          "caption": true,
          "community": "community",

        },
       
        "Port": {
          "thickness": "weight",
          "caption": true,
          "community": "partition",

        },
  
        "API": {
          "thickness": "weight",
          "caption": true,
          "community": "community",

        },
              },

      cluster_labels: {
        "Parameter": "partition"
      },

      initial_cypher: cypherQuery,
      arrows: true,
      hierarchical_layout: true,
      hierarchical_sort_method: "directed",

    };
    this.containerIdSingular = new NeoVis.default(config);
    this.containerIdSingular.render();
    this.loading = false;
    console.log(containerIdSingular);
  }

[3]
For a particular node -

Color Property
----------------

CALL algo.labelPropagation('NGOConnectionService','Parameter','OUTGOING',{write:true, partitionProperty:'community', weightProperty:'count'})

where - NGOConnectionService -> node
and
'Parameter' - > Relationship.

[4] Neo4j query reference -

[5] You can change the color of the nodes in Neo4j app by including the .grass file. Check out this post -

Regards,
Sucheta