Using variables in CrossTab

The variables pane contains two top-levels folders.  The Metadata folder contains metadata variables set up for the prototypes or samples (if any exist) for the current database.  The Profile Variables folder contains a folder for each of the four levels of reporting available within CrossTab.

The Profile folder contains profile variables relating to panellists defined in the database.  The Contact History, Event History and Email History folder contain variables relating to activity of panellists within the panel.

To view the variables available for use in the CrossTab report expand the variable hierarchy by clicking on the plus sign next to each folder.

The profile variables that are shown in CrossTab are defined in Q_Panel Hierarchy Manager, which can be found within the Maintenance menu.  In order to be available in CrossTab, a variable must have the ‘Allowed in CrossTab row/column’ checkbox ticked.

Using numeric variables

When a numeric variable is selected for a column or row a numeric range must be entered.  The report will display the results within the ranges defined.

For example, when the Age variable is dragged in Column, the Numeric Range dialog is displayed:

Individual values or ranges of values can be entered, separated by commas.  The range should be specified in ascending numerical order, and any negative numbers must be enclosed in single quotes.

When the report is executed the counts are displayed within the ranges specified.

The Uncoded column shows the number of records where the Age is outside the range specified.

If the Execute button is disabled, this could mean that a numeric range has not been specified or is invalid.  Edit the Row or Column to correct the problem.

Using date variables

When a date variable is selected for a column or row a date range must be entered.  The report will display the results within the ranges defined.

For example, when the Interview Date variable is dragged in Row, the Date Range dialog is displayed:

Specify whether you require to analyse by Days, Weeks, Months or Years, and enter the range.  Individual values or ranges of values can be entered, separated by commas.  Any negative numbers used must be enclosed in single quotes.

When the report is executed the counts are displayed within the ranges specified.

In this example, a range of years has been specified.  Year 0 means the current year, year 1 the previous year etc.  If the date variable you are using contains dates in the future, you will need to use a negative date range e.g. year ‘-1’ would mean next year.

If the Execute button is disabled, this could mean that the date range has not been entered or is invalid, for example the ranges may be overlapping.  Edit the date range for the Row or Column to correct the problem.

Using Metadata variables

Metadata variables can be used in the same way as other variables.  The crosstab will be executed at Sample History level if one or more of the variables used in Column, Row or Filter is a Metadata variable.  This means that Metadata variables can be used along with variables from the Profile and/or Contact History folder.

Using other types of variables

CrossTab reports cannot currently use text-based variables for analysis.

When using single-code profile variables in a Column or Row they will be displayed using the sort order defined in Q_Panel, however multi-code profile variables will be displayed using the code order.

When using activity variables in a Column or Row, such as Outcome Codes, Event Type or Prize Description, they will be displayed in alphabetical order.  It is not currently possible to change the order that these are displayed.

Increment variables are covered in another article.