Survey Tabulation > Working with hierarchical data > The hierarchical variable list
 
The hierarchical variable list
This topic describes working in the Variable List when you are using the hierarchical view of the data. Note that when you are using the flat view, although grids and loops are shown as expandable items, you cannot create a grid table, or use a variable that is inside a loop or grid in a table as described in this topic. However, you can use a slice of a grid or expanded loop in a table.
The Variable List represents loops and grids as expandable items, similar to folders in Windows Explorer. Click the grid or loop to expand it. This reveals the variables that are contained within the loop or grid.
The Variable List
You can use the variables inside the loops and grids in your tables, in the normal way. However, you need to understand the significance of populating your tables at the various levels. See Understanding population levels for more information.
You can use grids and loops that are defined as expanded to create grid tables. If you look at the person loop in the picture above, you will see that it has a special icon to indicate that it is expanded. Grids do not have this icon because they are expanded by default. When you look at the variables inside a grid or expanded loop, you can see the iterations. For example, in the household survey, there is a rating grid inside the vehicle loop. When you double-click the variable that is inside the grid you can see the iterations.
The Variable List, expanded
See Understanding grid tables for more information.
The iterations are sometimes called grid or loop slices and you can use them in your tables. See Grid and loop slices for more information. The iterations are not shown for loops that are unbounded.
When you are working with hierarchical data, it is often useful to be able to see the full names of the variables, because the full names indicate exactly where each variable fits in the overall hierarchy. You can easily add a column to show the full names. See Changing the columns in the Variable List for more information.
The Variable List showing full variable names
To understand how full names work, it helps to think in terms of parents and children. For example, variables that are nested inside a loop can be considered the children of the parent loop. The full names are constructed by the UNICOM Intelligence Data Model by combining the names of the variable and its parents (if any). Brackets ([ ]) indicate iterations and a single period (.) indicates a parent/child relationship.
Two periods are used inside the brackets ([..]) to indicate all iterations. In the Household sample, the vehicle loop is an unbounded loop, which means that you cannot access individual iterations. This is represented by the [..] in the full names of its children.
The rating grid, on the other hand, is defined as expanded, which means that you can access individual iterations. If you look at the iterations shown for the Column variable inside the rating grid, you can see that the name of the category that controls the iteration is shown in brackets in the full name.
Note Compounds and blocks are used to group questions for display or convenience only and do not define a true hierarchical structure. Therefore, you cannot use compounds and blocks to create grid tables. However, you can use the variables that are nested within a compound or block in your tables in the normal way.
 
See also
Working with hierarchical data