Randomize Responses: Variable Value
This article will show you how to use a hidden variable to manually create an order
You may have the need to create a random order within a variable and use that to randomize a response list. The instructions below will show you how.
Step 1: Creating the Variable
- Program a 'Single Variable' without a response list
- See article: Add a Variable
- Add a logic a 'Logic Block Page' in a location before the random order will be used.
- See article: Add a Logic Block Page
- Using the formula syntax, set the variable to the order you need. Please note, the order must be a comma delimited list wrapped in quotes. Example: You have a question with a response list containing 5 items. You want the order to always be:
So you would set your variable to:
"1, 3, 4, 5, 2"
Step 2: Using the order variable within the question
- Program your question with the corresponding response list
- Access the 'Overall Question Settings'
- See article: Overall Question Settings: Accessing
- Turn on the 'Custom Response Order' toggle.
- Select 'Variable Value' from the drop-down
- Select the name of the 'Single Variable' you created
- Choose between:
- Apply to 'Ordinals' (Position of the Codes)
- Apply to 'Names' (exact Code numbers)
- You are done! Make sure to test.