# Relationships are not showing in the graph by using neovis.js

**URL:** <https://community.neo4j.com/t/relationships-are-not-showing-in-the-graph-by-using-neovis-js/2591>\
**Category:** Neo4j Visualization Library (NVL)\
**Tags:** cypher, neovis\
**Created:** [October 23, 2018, 2:05pm UTC](https://community.neo4j.com/t/relationships-are-not-showing-in-the-graph-by-using-neovis-js/2591 "2018-10-23T14:05:46Z")\
**Posts on this page:** 6\
**Page:** 2

<div class="post-metadata">

**Author:** ![sucheta](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/sucheta/32/4444_2.png) [@sucheta](https://community.neo4j.com/u/sucheta)\
**Post date:** [January 17, 2019, 4:45am UTC](https://community.neo4j.com/t/relationships-are-not-showing-in-the-graph-by-using-neovis-js/2591/21 "2019-01-17T04:45:50Z")

</div>

Hi Michael,

The output for the query you mentioned is a Syntax error.

First i ran this cypher -

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

O/p -

 ![labelPropogation-17thjan](https://us1.discourse-cdn.com/flex021/uploads/neo4jcommunity/original/2X/7/785fe9bed2c993d350eff099dc2a68855f3a9628.png)

Then i ran this command -

```auto
match (n)
return head(labels(n)) as lab, n.partition as partition, count(*) as count
order by label, count desc;

```

o/p -

 ![countlabels_17th%20jan](https://us1.discourse-cdn.com/flex021/uploads/neo4jcommunity/original/2X/2/2d058303f3a9b82985ff5143f1f17703da39bdc8.png)

Please suggest

---

<div class="post-metadata">

**Author:** ![michael.hunger](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/michael.hunger/32/27377_2.png) [@michael.hunger](https://community.neo4j.com/u/michael.hunger)\
**Post date:** [January 17, 2019, 11:46am UTC](https://community.neo4j.com/t/relationships-are-not-showing-in-the-graph-by-using-neovis-js/2591/22 "2019-01-17T11:46:55Z")

</div>

You should be able by now to fix it yourself 🙂

```auto
match (n)
return head(labels(n)) as label, n.partition as partition, count(*) as count
order by label, count desc;

```

---

<div class="post-metadata">

**Author:** ![sucheta](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/sucheta/32/4444_2.png) [@sucheta](https://community.neo4j.com/u/sucheta)\
**Post date:** [January 17, 2019, 12:00pm UTC](https://community.neo4j.com/t/relationships-are-not-showing-in-the-graph-by-using-neovis-js/2591/23 "2019-01-17T12:00:29Z")

</div>

Sorry michael, but i don't understand the result and how to interpret it so as to solve my issue of color.

O/p is -

 ![query-count-labels](https://us1.discourse-cdn.com/flex021/uploads/neo4jcommunity/original/2X/e/e8c1c2a5bbe1e7df26b09d157cdc483e84331751.png)

Please help ✌

---

<div class="post-metadata">

**Author:** ![michael.hunger](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/michael.hunger/32/27377_2.png) [@michael.hunger](https://community.neo4j.com/u/michael.hunger)\
**Post date:** [January 17, 2019, 10:22pm UTC](https://community.neo4j.com/t/relationships-are-not-showing-in-the-graph-by-using-neovis-js/2591/24 "2019-01-17T22:22:44Z")

</div>

1. all your partitions are very small only 1 to 3 nodes
2. I guess you have mixed up the property names? partition vs. community (which you used in neovis) to contain the partition-id?

---

<div class="post-metadata">

**Author:** ![sucheta](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/sucheta/32/4444_2.png) [@sucheta](https://community.neo4j.com/u/sucheta)\
**Post date:** [January 18, 2019, 11:18am UTC](https://community.neo4j.com/t/relationships-are-not-showing-in-the-graph-by-using-neovis-js/2591/25 "2019-01-18T11:18:55Z")

</div>

I have mixed property name - partition vs. community . Because i entered -\> partition in the below query -

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

And when i defined the config file -

"community" : "partition"

The nodes donot get the responsive color. However, when i entered "community" : "community" i get proper output for the label defined in config variable.

> labels: {  
> "Parameter": {  
> "thickness": "weight",  
> "caption": "name",  
> "size": "pagerank",  
> "community": "community",  
> "sizeCypher": "MATCH (n) WHERE id(n) = {id} MATCH (n)-[r]-() RETURN sum(r.weight) AS c"  
> }  
> }

Please explain as to why i get same color for Nodes with label - Parameter, even though they also have count 1-2

```auto

label partition count

|"Operation"| 622| 1|

|"Organization"| 2| 1|

|"Parameter"| 640| 3|

|"Parameter"| 631| 3|

```

---

<div class="post-metadata">

**Author:** ![michael.hunger](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/michael.hunger/32/27377_2.png) [@michael.hunger](https://community.neo4j.com/u/michael.hunger)\
**Post date:** [January 18, 2019, 7:08pm UTC](https://community.neo4j.com/t/relationships-are-not-showing-in-the-graph-by-using-neovis-js/2591/26 "2019-01-18T19:08:48Z")

</div>

Probably a limit of colors.

I think you have a better way of trying a simple setup

Where you set (a few, e.g. two) labels and properties manually (partition, pagerank) on a few (e.g. 10-20 nodes) and see how they are rendered and take it from there. I think in your current graph you have too many moving parts that might be confusing.

You can also follow the example from neovis that uses the Game of Thrones graph interaction graph.

[Previous page](https://community.neo4j.com/t/relationships-are-not-showing-in-the-graph-by-using-neovis-js/2591.md?page=1)
