This setup will populate a flag question, based on certain criteria in your study. A standard Single Choice question will be used as the flag and if there is data in this question, then the respondent has met the criteria you wish to flag. If there is no response in the question, then the respondent has not met the criteria.
Example
You need to flag respondents who select an incorrect option, but not disqualify them from your survey. You can create a flag for use in filters/reports to determine how many people selected the incorrect option.
Note: If the back button is enabled in your study, and the respondent changes his/her answers and does not meet the criteria any more, the flag will still have previous data.
Detailed Steps
Create the question and conditional sequence:
- In Power Survey Authoring, click the Questionnaire tab.
- Create a Single Choice question to act as the flag.
- Ensure that this question has one answer option only, and the text of this option should be descriptive of the condition. Example: Incorrect Response for Question Q5.
- Ensure that the Single Choice question is either hidden or after the completion point of your study, so that respondents do not see it.
- Create a Conditional Sequence in your study. The condition should be updated to the criteria for flagging the respondent.
Example: If you want to flag respondents who selected option 1 at Q5, then your Conditional Sequence will reflect this.- As a best practice, this Conditional Sequence should be immediately after the question being referenced in the condition. In the example above, you would place the conditional sequence right after Q5. If you are referencing multiple questions, you can place the Conditional Sequence after the last question the respondent sees.
- Add a Script Action within the conditional sequence. To add a Script Action, on the Authoring Navigation Bar, hover over Action, and then select Script.
Prepare the script in Notepad:
- Open Notepad or a similar text editing tool.
- Copy the script below into Notepad.
- Change FLAG_Q to the name of your Single Choice flag question.
- Save the completed script in Notepad.
Script:
/*
Script Name: How do I flag respondents who meet certain criteria?
To ensure your script works as expected, always copy the original script from the script library found in the support portal. Failure to use the most up to date script from the script library may cause unexpected results.
*/
Set(FLAG_Q, 1);
Insert the completed script into your study:
- Copy the completed script from Notepad.
- Select the Script Action in the Questionnaire Tree.
- Paste the script into the Script Action.
- Click Save.
- Validate and test your study.
Note: If you want to set up multiple flags within your study, you can repeat this entire process for each flag required.
More Information
Please click the WebHelp links below for more information:
Comments
0 comments
Article is closed for comments.