Using a relationship diagram

Contents[Hide]

1. Overview

The relationship diagram arranges items in your data based on the relationships between them in a freeform graph. Use it to discover unexpected links, group data into clusters according to their relationships, or add additional details or quantitative data (measures) on top of the structure it displays.

While this diagram can be used to display the hierarchical structure and grouping of any data you add to it, it is also capable of visualizing whatever forms of relationships might exist between values in your data by assigning Source and Target values.

2. Add a relationship diagram

Using the Data Visualization or Re-Visualize option in the toolbar, select Relationship Diagram.

Select Relationship Diagram
Select Relationship Diagram

If you haven't already selected data, drag it from the Explore window onto Rows to determine what will make up the nodes (circles) of the diagram.

To select and visualize multiple levels from a multi-level hierarchy at once, click to edit the hierarchy in the Data Analysis Panel, then set the Top Level to be different from the Level.

Set the Top Level to be different from the Level
Set the Top Level to be different from the Level

In our example below, the diagram now displays a tree-like arrangement based on the multiple levels of a hierarchy.

Tree-like arrangement of relationship diagram
Tree-like arrangement of relationship diagram

Instead of creating a multi-level hierarchy, you can add multiple hierarchies or columns of data.

This type of diagram is known as a force-directed graph and is non-deterministic, which means it will initially be arranged differently each time it loads based on its current data.

You can zoom in and out, and click and drag nodes to re-arrange them (first click View in the toolbar if editing a dashboard or another view). Drag a child node to move it, or drag a parent node to move the whole cluster. When dropped, nodes will gravitate toward the parent node and the whole cluster will gravitate toward the center.

2.1. Display custom relationships

By default, the relationship diagram displays the hierarchical structure between the hierarchies and levels you've added. To display custom relationships between nodes, assign values as sources and other values as targets from rows of data that can identify pairs of nodes that each represent a relationship. For example, data corresponding with messages may have a from and to address.

To assign sources and targets, click the Visualization tab in the Data Analysis Panel.

Select Visualization in the Data Analysis Panel
Select Visualization in the Data Analysis Panel

Remove any data not being used as a source from under Source Name (and add it if missing).

Drag data from the Explore window or click to add data under Target Name.

Simple custom relationships between countries and country groups
Simple custom relationships between countries and country groups

By default, links appear as straight lines connecting two nodes. If the relationships between items in your data have an associated direction, select the Show Link Arrows option in the Properties window. The links will be drawn as arrows from each source to the target.

Directional links
Directional links

If there are multiple links in your data between the same nodes (e.g., links in both directions), displaying them as straight lines will result in overlap and this relationship will be harder to see. To better visualize this type of relationship, change the Link Type property to Curve.

Curved links in both directions
Curved links in both directions

In the Data Analysis Panel's Visualization tab under Links, you can assign data under Color, Length, and/or Width to vary each link according to its values.

Add a measure to Color
Add a measure to Color

When data is assigned, color rules or size rules are created in the corresponding properties in the Properties window (e.g., an Auto Color Rule in the links' Color Rules). To change or customize these, click the brush icon next to the option in the Data Analysis Panel to go to the corresponding properties, or find them in the Look tab.

Measures added to Length and Width
Measures added to Length and Width

Length Rules apply length values to links, and Stroke Width Rules apply width values to links.

Color and size rules work the same as in other visualizations, such as charts. For more details, see Apply colors to data points or series using color rules.

4. Displaying node values and details

4.1. Adding a second metric set

If you have assigned data under Target Name to display custom relationships, the rows of your data each identify a pair of nodes. To display or visualize data for individual nodes, a second metric set must be added to the visualization.

Note
This does not apply to a diagram where no data was assigned under Target Name – in this case you can visualize data for each node as shown in the following section using only a single metric set.

When editing a metric set directly in the full-screen editor, it must be added to a dashboard or another view first before another metric set can be added. You can do this by choosing Add To New Dashboard in the toolbar.

In the Metric Set tab of the Data Analysis Panel, click the Add New or + button.

Add a new metric set
Add a new metric set

Drag data identifying each node onto Rows. These values should correspond with the values already used as source and target names.

Switch to the Visualization tab to confirm the data assigned under Name for the nodes. You can now assign this metric set's data as node color, size, label, or tooltip, as shown below, or use node state styles.

4.2. Change node appearance

In the Visualization tab of the Data Analysis Panel, you will find the Nodes section available when your second metric set is selected, or when you have a single metric set if no data was assigned under Target Name in the Links section.

Add a measure to Color for nodes
Add a measure to Color for nodes

As with the links, color or size rules are created automatically when data is assigned as Color or Size. These can be changed or customized in the Properties window in the Look tab, and you can click the paintbrush icon next to the option in the Data Analysis Panel to go to the corresponding properties.

Add a measure to Size for nodes
Add a measure to Size for nodes

To display different images in each node instead of a color, assign data that can be used to find those images to Image, and optionally customize the corresponding Image Path property in the Look tab of the Properties window if your data does not already contain a full URL to the image. This property works the same way as the Image Path property in other visualizations, similar to how you can combine values from data with static text for labels and tooltips as shown in the following section. 

5. Change labels and tooltips

In the Text tab of the Properties window, you can customize the Label Text and Tooltip Text properties for both the links and the nodes.

These properties accept regular text, as well as keywords such as [Member] and [Level] for the hierarchy member and level caption respectively, which will be suggested for you as you edit the property. For additional information about available keywords, refer to the Formatting text article.

To display specific values from your metric set, you can enter keywords, or you can assign data to Label or Tooltip in the Visualization tab of the Data Analysis Panel.

Add a measure under Label for links
Add a measure under Label for links

After assigning data in the Data Analysis Panel, you can click the paintbrush icon next to the heading to open the corresponding properties.

Customizing link label properties
Customizing link label properties

6. Selected styles

You can adjust how nodes or links appear when selected by hovering over them or through data brushing.

In the Look tab of the Properties window, click Selected Style in the applicable section.

Click Selected Style to adjust the selected style
Click Selected Style to adjust the selected style

As an example, change the Selected Style for links to use Red strokes of a 2-pixel width.

Change the Selected Style for links
Change the Selected Style for links

In the Main tab of the Properties window, select Highlight Related Links if all connected links should highlight at once when a node is selected.

Enable highlighting all related links
Enable highlighting all related links

If editing a view such as dashboard, switch to View in the toolbar before hovering over data in the diagram.

Hover over a source node
Hover over a source node

7. See also

Dundas Data Visualization, Inc.
400-15 Gervais Drive
Toronto, ON, Canada
M3C 1Y8

North America: 1.800.463.1492
International: 1.416.467.5100

Dundas Support Hours:
Phone: 9am-6pm, ET, Mon-Fri
Email: 7am-6pm, ET, Mon-Fri