Skip to main content
Version: 9.3

Hierarchical Data

Hierarchical data allows you to organize information in a nested structure to represent parent-child relationships. Qrvey can work with hierarchical data to create detailed, multi-level data visualizations and analyses.

Note: Hierarchical datasets are only available in Qrvey Ultra.

Create a Hierarchical Dataset

Hierarchical data is often uploaded as a JSON file.

  1. Navigate to Data > Dataset.

  2. Select New Dataset. A modal opens.

    hierarchical-data

  3. From your connections list, locate a JSON file.

  4. Select Create to open a modal.

View Hierarchical Dataset

Select an existing hierarchical dataset to review any existing numeric or text arrays, objects, or object arrays in your JSON file.

For example, assuming the following JSON structure:

[
{
"Name":"John Smith",
"DOB":"12/23/1975",
"children":2,
"childrenAges":[10,12], // numeric array
"carModels":["Ford","Chevy"], // string array
"address": { "city":"Chicago", "state":"IL"}, // object
"countriesVisited":[ // object array
{ "id":10, "country":"Germany" },
{ "id":15, "country":"Spain" },
{ "id":18, "country":"Iraq" }
]
}
]

The Data > Dataset > Columns page registers these new data structures.

  • The user interface displays new column types such as Numeric Array, Text Array, Object, and Object Array.
  • The address column is an object that contains its own nested columns.
  • The countriesVisited object array contains its own nested columns. The column and its children are not selected and are disabled.

hierarchical-data

You can also go to the Data > Dataset > View Source Data tab to see how the raw data is registered in Qrvey.

Hierarchical data

The parent records in the main data source have a one-to-many relationship with countriesVisited object array, which can act like a left join between two relational tables and can be “inflated” to produce a flat dataset.

Customize Hierarchical Datasets

Before loading your dataset, you can apply Transformations, modify the design, and flatten object arrays.

To flatten an object array, follow these steps.

  1. Select Transformations in the top right corner of the columns list.
  2. Drag the Array Flatten transformation to the workspace.
  3. Select the Inflate option from the dropdown.
Hierarchical data columns

When the Transformation modal closes, the transformation flattens the array. You can view the result on the Dataset Design tab.

View source data