The mark as
tag (alias mark
) provides Survey Programmers (SPs) a shortcut for referencing variables within conditional statements for closed-end options. Rather than using more "traditional" conditional statements such as show if: anyChecked($QS3,1)
, which requires SPs to know the original variable/question and option IDs, instead the mark
tag can be applied to a question and define a variable based on existing options that can be referenced later. SPs may also apply a variation of this tag as an element decorator, or apply multiple mark
tags to a single variable.
Syntax
# As a decorator 1. Question text type: radio 1. Option 1 {mark: VAR_NAME1} 2. Option 2 {mark: VAR_NAME2} # As a tag 2. Question text type: radio 1. Option 1 2. Option 2 3. Option 3 mark: VAR_NAME1 {if condition} mark: VAR_NAME2 {if condition} # referencing a "marked" variable 3. Question text type: radio, checkbox, etc. showif: $VAR_NAME1 1. Option 1 2. Option 2
Examples
As a decorator
For simple conditions, the mark as
(or mark
) decorator can be applied after an option's text by simply specifying a variable name for the option.
As a tag
When applied as a tag, mark
requires a variable name followed by a condition for qualifying for the variable. In QS2, respondents who answered either option '1' or '2' will be assigned to 'MALE' or 'FEMALE', respectively.
Compound conditioning
The mark
tag can also accept compound conditions. In the example below, two marked variables have been created, 'YOUNGER_MAN' and 'OLDER_MAN'. Respondents may be placed in either category based on their responses to QAGE and if they selected 'male' in QS3.
Referencing marked variables
Once a marked variable has been defined, it can be referenced in later questions for conditioning display logic. Both QS4 and QS5 use the showif
tag to reference marked variables created from QS3 to determine whether the respondents will see them or not.
Marks with multiple definitions
Marked variables do not have to be restricted to being defined by a single option, and a single marked variable can be defined by multiple options from a question or table. Note that SPs cannot define the marked variable across questions/tables or variables and will receive a parse error if they attempt to do so. In other words, the marked variables 'RVS', 'POWERSPORTS', and 'MARINE' shown in Q4 cannot also be defined in other questions.
Defining with decorators:
Defining instead with multiple mark
tags:
Qualifying for multiple marked variables
In certain situations, it might be necessary for options to qualify for multiple marked variables. In the below example, the fruit options have been assigned to three different marked groups – 'citrus', 'berries', or 'melon' – and depending on the respondents selections, they could potentially be assigned to all three. In addition, some of the choices qualify for a 2nd marked variable, 'orangefruit', even though they are not all from the same initial marked group.
Marked variables in reporting
When the mark
tag or decorator is applied to a variable, additional variables become available in the Field Selector in various reporting applets. Under the Survey fields chapter, a 'mark' variable will be listed which acts as a summary of all mark variables applied to survey fields. In addition to that, a Markers sub-folder will appear under System fields, which includes an individual field for each marked variable with its defined logical expression (when the mark
tag was applied to a question) or description (when the mark
element decorator was applied to an option). In the image below, the marked variables 'MALE' and 'FEMALE' were defined via the mark
decorator whereas 'YOUNG_MAN' and 'OLDER_MAN' were defined via the mark
tag.
In Topline Reports, the 'mark' summary tile displays the variable name for each marked variable along the Y-axis (vertical axis). Hovering over one of the graph's bars, a tooltip will appear with the variable name and both the percent and raw numbers of respondents who qualified for that variable's assignment.
Individual marked variable tiles will include the definition used to sort respondents as "Marked" or "Not marked." Fields that included the mark
tag will include the original question ID and the condition logic used to define the qualification for the marked variable (below left). Fields that included the mark
element decorator will display the original question ID and the option to which the decorator was attached (below right).
Comments
0 comments
Please sign in to leave a comment.