|
| 1 | +A bar chart will draw categories and values in a familiar bar-layout. |
| 2 | +The bar chart will require you to choose the following selections: |
| 3 | + |
| 4 | +* *Category*: a text field. These will be the labels on the bars. |
| 5 | +* *Value*: a numeric field. This will be the height of the bars. |
| 6 | +* *Group*: Optionally, a second textual field. When ``Grouping'' is |
| 7 | +enabled in the advanced settings, the group can be used to draw a |
| 8 | +stacked bar chart, with several groups per category. |
| 9 | +
|
| 10 | +== Examples |
| 11 | + |
| 12 | +=== Simple Bar Chart |
| 13 | + |
| 14 | +[source,cypher] |
| 15 | +---- |
| 16 | +MATCH (p:Person)-[e]->(m:Movie) |
| 17 | +RETURN m.title as Title, COUNT(p) as People |
| 18 | +---- |
| 19 | + |
| 20 | +image::./img/bar.png[Basic Table] |
| 21 | + |
| 22 | +=== Stacked Bar Chart |
| 23 | + |
| 24 | +[source,cypher] |
| 25 | +---- |
| 26 | +Match (n:Person)-[e]->(m:Movie) |
| 27 | +RETURN m.title, COUNT(p) as People, type(e) as Role |
| 28 | +---- |
| 29 | + |
| 30 | +image::./img/barstacked.png[Basic Table] |
| 31 | + |
| 32 | +== Advanced Settings |
| 33 | + |
| 34 | +[width="100%",cols="19%,17%,26%,38%",options="header",] |
| 35 | +|=== |
| 36 | +|Name |Type |Default Value |Description |
| 37 | +|Show Legend |on/off |off |If enabled, shows a legend at the top right |
| 38 | +of the visualization. |
| 39 | + |
| 40 | +|Grouping |on/off |off |If enabled, lets users specify a third, grouping |
| 41 | +field. This is used to distinguish between different groups in the |
| 42 | +stacked bar chart. |
| 43 | + |
| 44 | +|Value Scale |List |linear |When set to symlog, uses a Symmetric |
| 45 | +logarithmic scale instead of the default linear scale. |
| 46 | + |
| 47 | +|Min Value |Number |auto |If not set to ``auto'', this variable is |
| 48 | +minimum value for the bar chart. |
| 49 | + |
| 50 | +|Max Value |Number |auto |If not set to ``auto'', this variable is the |
| 51 | +maximum value for the bar chart. |
| 52 | + |
| 53 | +|Group Mode |List |stacked |This setting determines how different groups |
| 54 | +are visualized when grouping is enabled. If set to stacked, different |
| 55 | +groups of the same category are stacked on top of each other. If set to |
| 56 | +grouped, they are placed alongside each other. |
| 57 | + |
| 58 | +|Layout |List |vertical |Whether to use a vertical or horizontal bar |
| 59 | +chart layout. |
| 60 | + |
| 61 | +|Color Scheme |List | |The color scheme to use for the category groups. |
| 62 | +Colors are assigned automatically (consequitevely) to the different |
| 63 | +groups returned by the Cypher query. |
| 64 | + |
| 65 | +|Show Values on Bars |on/off |off |If enabled, shows the category value |
| 66 | +inside the respective bar. |
| 67 | + |
| 68 | +|Label Rotation (degrees) |number |45 |the angle at which the bar labels |
| 69 | +are rotated. |
| 70 | + |
| 71 | +|Margin Left (px) |number |50 |The margin in pixels on the left side of |
| 72 | +the visualization. |
| 73 | + |
| 74 | +|Margin Right (px) |number |24 |The margin in pixels on the right side |
| 75 | +of the visualization. |
| 76 | + |
| 77 | +|Margin Top (px) |number |24 |The margin in pixels on the top side of |
| 78 | +the visualization. |
| 79 | + |
| 80 | +|Margin Bottom (px) |number |40 |The margin in pixels on the bottom side |
| 81 | +of the visualization. |
| 82 | + |
| 83 | +|Legend Width (px) |number |128 |The width in pixels of each legend |
| 84 | +label on top of the visualization (if enabled). |
| 85 | + |
| 86 | +|Hide Selections |on/off |off |If enabled, hides the property selector |
| 87 | +(footer of the visualization). |
| 88 | + |
| 89 | +|Auto-run query |on/off |on |when activated automatically runs the query |
| 90 | +when the report is displayed. When set to `off', the query is displayed |
| 91 | +and will need to be executed manually. |
| 92 | +|=== |
| 93 | + |
| 94 | +== Rule-Based Styling |
| 95 | + |
| 96 | +Using the link:Reports#rule-based-styling[Rule-Based Styling] menu, the |
| 97 | +following style rules can be applied to the bar chart: |
| 98 | + |
| 99 | +- The color of the bar. |
0 commit comments