aytm Logic Glossary
[...] |
aytm Logic must always be surrounded by square brackets |
---|---|
Q |
question |
SQ |
subquestion |
E |
entity |
A |
answer |
R |
response |
Rn |
number of responses |
Rc |
all comments, comma separated |
Ri |
first image |
c |
comment |
i |
image |
@ |
field alias |
or |
“or” operator |
. |
alternative “or” operator |
- |
alternative “or” operator - used for ranges |
and |
“and” operator |
, |
alternative “and” operator |
: |
alternative “and” operator - used for ranges |
+ |
add |
- |
subtract |
* |
multiply |
exp |
exponent |
** |
pow |
^ |
pow |
/ |
division |
> |
greater than |
< |
smaller than |
>= |
greater or equal than |
<= |
smaller or equal than |
= |
equal to |
!= |
not equal |
<< |
add to array |
, |
(in array context) add more items to array |
| |
(in array context) value at position in array |
in |
is there at least one in the following array |
like |
is there at least part of text in the following array |
not |
negative condition statement |
then |
(in group logic) initiate nested group logic |
1 |
numeric value or a variable, number of a field |
“one” |
string value of a custom variable (can contain any symbols as long as it’s in quotes) |
(...) |
operations in parentheses will be processed before others |
punch |
automatically record answer(s) for respondents without requiring them to view the question |
[Show] |
show a field |
[Hide] |
hide a field |
[Show if...] |
show a field if a condition is met |
[Show first / last...] |
show a number of first / last elements |
[Hide if...] |
hide a field if a condition is met |
[Skip to...] |
skip to a destination if a condition |
[Skip to… if] |
skip to a destination if a condition is met |
[Glue...] |
- keep elements together |
[Mask by...] |
mask a question based on selected answers to an earlier question |
[Rev-mask by...] |
mask a question based on non-selected answers to an earlier question |
[Group...balance...max...] |
create nodes, group them together, show them randomly to respondents; optionally ensure balanced representation across variables; optionally limit the number of nodes per respondent |
[Sort ... by ...] |
sort elements by array |
[Sort by a-z ...] |
sort elements alphabetically (a-z or z-a) |
[VarName...] |
a way to introduce a custom variable where VarName can be anything you choose using (A-Z, a-z, 0-9 and the underscore symbol "_") |
[[Anything]] |
a way to show respondent any regular phrase in square brackets |
Examples
[PQ1] |
Reference to first prequalification question |
---|---|
[Q1] |
Reference to the first question |
[Q1A1] |
Reference to the first answer of the first question |
[Q1SQ1A1] |
Reference to the first answer of the first sub-question of the first question |
[Q1E1SQ1A1] |
Reference to the first answer of the first sub-question (attribute) of the first entity of the first question. Relevant in Competitive Topography and Quadrant questions. |
[Q1i] |
Reference to the image, attached to the first question |
[Q1A1p] |
Position ("first", "second" ...) of the referenced item |
[Q1A1pv] |
Position (1, 2 ...) of the referenced item |
[Q1cv] |
Converted comment response to number of the referenced item |
[Q1r] |
Reference to all responses, given by respondent to the first question |
[Q1r1] |
Reference to the first response, given by respondent to the first question |
[Q1rn] |
Number of response, chosen by respondent on the first question |
[Q1r1c] |
Comment, entered by respondent on their first response on the first question |
[Q1rc] |
All comments, entered by respondent on the first question |
[Q1r1i] |
Image, associated with the first response, chosen by respondent on the first Q |
[aytm_response_id] |
Reserved variable returning unique response identifier number, matches the first column in statistics page exports. Can be used as an identifier for complex redirections. |
[uuid] |
Reserved variable returning Unique User ID (if available) |
[var1] |
Reserved variable returning first custom variable, passed through the survey link (if available) |
[var2] |
Reserved variable returning second custom variable, passed through the survey link (if available) |
[var3] |
Reserved variable returning third custom variable, passed through the survey link (if available) |
[platform] |
Reserved variable returning type of respondent’s operating system (windows, mac, linux, ios, android, windows_mobile, windows_phone, other) |
[device] |
Reserved variable returning type of respondent’s device (undefined, pc, mobile, tablet) |
[browser] |
Reserved variable returning type of respondent’s browser (chrome, opera, firefox, ie, electron, safari, edge) |
[gender] |
Reserved variable returning type of respondent’s gender (f, m) |
[income] |
Reserved variable returning type of respondent’s HHI (0-25k, 25k-50k, 50k-75k, 75k-100k, 100k-200k, 200k-500k, 500k+) |
[education_level] |
Reserved variable returning type of respondent’s highest education (professionaldegree, nocollege, somecollege, 2yrdegree, 4yrdegree, gradschooldegree) |
[age] |
Reserved variable returning type of respondent’s current age (0-99) |
[children] |
Reserved variable returning type of respondent’s parental status. Digit represents number of kids (n/a, 0, 1, 2, 3, 4, 5+) |
[relationship_status] |
Reserved variable returning type of respondent’s relationship status (single, married, widowed, significantother, engaged, divorced, complicated) |
[ethnicity] |
Reserved variable returning type of respondent’s ethnicity (whiteamerican, africanamerican, nativeamerican, asianamerican, latinoamerican, multiracial, other) |
[employment] |
Reserved variable returning type of respondent’s employment status (fulltime, parttime, retired, unemployed, student) |
[career] |
Reserved variable returning type of respondent’s career (acc/fin/bank, adv/design, arts/ent, clerical, healthcare, hospitality, it, legal, management, military, publicsafety, realestate, retail, smbusiness, student, other) |
[region] |
Reserved variable returning respondent’s region code. For example, the logic to show question only to US respondents living in southern regions is: [show if country="US" and region="S"] |
[country] |
Reserved variable returning respondent’s country as ISO 3166 country code. For example, the logic to show question only to respondents living in France or Canada is: [show if country="CA" or country="FR"] |
[state] |
Reserved variable returning respondent’s state as ISO 3166 state code. For example, the logic to show question only to respondents living in Tucumán State, Argentina is: [show if country="AR" and state="T"] |
[county] |
Reserved variable returning respondent’s county as FIPS county code. For example, the logic to show question only to respondents living in Los Angeles County, California, US is: [show if county="06037"] |
[zip] |
Reserved variable returning respondent’s zip code. For example, the logic to show question only to respondents living in Los Angeles County, California, US, with specific zip code: [show if country="US" and zip="90001"] |
[completed] |
Reserved variable referencing respondent completion time on the Stats Page only. For example, the logic to filter for respondents who completed the study before August 1st, 2022: completed < 2022-08-01 00:00:00 |
[punch Q2a1, 5 as value, “n/a” as comment, if Q1a3]
|
For Q2, A1 will be recorded with a value of 5 with the comment “n/a” if the respondent selects A3 for Q1.) |
[vr_collected] |
Will be true if the respondent submitted a video |