VARIABLES
Introduction
The VARIABLES section is where you define script variables. These have an identical syntax to question definitions but by default are not included in the survey data when it is exported or analysed.
They are typically used to store temporary information during the running of the survey, such as calculations used in filters or checks, text-fill strings or loop iteration variables.
The declarations in this section should not be confused with question variables which are the variables automatically derived from question definitions which can be referenced directly in the ROUTE section of the DSC script and are the underlying representation of the data described.
Examples
The following example shows two simple script variables:
VARIABLES
i : INTEGER
s : STRING
By default these are not included in the exported data, but you can override this behaviour with the DATA keyword. For example:
VARIABLES
k "Something important" : INTEGER DATA
It is good practice to include metadata such as a label in variables you intend to export, as shown in the above example.