Randomizing options in a categorical question

Our user Hao Xue has sent us the following question:

We are working on a list experiment, which requires to randomly show the options of a question in a questionnaire to different interviewees. I want to know whether it is possible in Survey Solution. Thank you very much! For example: the first and the second versions of options of one question are as follows.

P.D01. How many of these conditions you would feel comfortable conducting a physical exam on a patient with this condition. Again, please don’t tell me which ones you are comfortable with, just the number of conditions you’re okay with.

Version 1:
1 = Neurological disorder
2 = Leprosy
3 = Patient with poor hygiene
4 = Foreigner (unable to speak Chinese)
□1 □2 □3 □4 □ Prefer not to answer

Version 2:
1 = Patient with poor hygiene
2 = Leprosy
3 = Neurological disorder
4 = Foreigner (unable to speak Chinese)
□1 □2 □3 □4 □ Prefer not to answer

I am not sure how a categorical question be formulated as “How many…
Please elaborate what TYPE of question is that.

In the absence of any other comment or clarification from Hao Xue, I have put it the way I see it to the following example questionnaire: “PUBLIC EXAMPLE Randomize question content”

I am sorry to make it confused! Basically we want to randomly show the order of options in a question, but I don’t know how to do it in the Survey Solution.

For example, we can show version 1 to the first interviewee and version 2 to the second interviewee. Of course, there are also other versions if there are four options in a question.

Version 1
1 = Neurological disorder
2 = Leprosy
3 = Patient with poor hygiene
4 = Foreigner (unable to speak Chinese)

Version 2
1 = Patient with poor hygiene
2 = Leprosy
3 = Neurological disorder
4 = Foreigner (unable to speak Chinese)

The example questionnaire: “PUBLIC EXAMPLE Randomize question content” shows how one of the two versions of the question can be shown. You turn that numeric into a categorical with the options as shown in your paragraph above.

Certainly. You can include more, adjusting the probabilities in the enabling conditions (they are 50/50 in the case of only 2 versions provided, but 33/33/34 and 25/25/25/25, etc as the number of versions increases).

I am sorry but I did not find the “PUBLIC EXAMPLE Randomize question content” in the shared public questionaries in the designer. Would you please share the link of it? Thank you!

Hello @haoxuereap,

it is in the Randomization demos folder.

Best, Sergiy

Hi, thanks for the answers @sergiy. I am a teammate of @haoxuereap. We work on this questionnaire together. I want to add something to this question. Here’s the sample of the questions:
How many of these conditions you would feel comfortable conducting a physical exam on a patient with this condition. Again, please don’t tell me which ones you are comfortable with, just the number of conditions you’re okay with.
Version 1
1 = Neurological disorder
2 = Leprosy
3 = Patient with poor hygiene
4 = Foreigner (unable to speak Chinese)

Version 2
1 = Patient with poor hygiene
2 = Leprosy
3 = Neurological disorder
4 = Foreigner (unable to speak Chinese)
5 = TB

As you can see, there are 4 options in version 1 while there are 5 in version 2. We want to randomly show one of these 2 questions to the participant. We tried copying the setting in the example questionnaire “PUBLIC EXAMPLE Randomize question content” and it never worked. Could you please advise?

Thanks a lot!

Define what does “it never worked” mean, please.

Thanks for the prompt response. It always pops up “Error occured” even if I copied the whole questionnaire. I am wondering if that is the right way to set up this kind of question.

Sorry I wasn’t being clear enough. I set up a questionnaire just to test the randomization. So the questionnaire has only 1 question. After a few attempts, I deleted my questions and copied the example questionnaire to my questionnaire, it still showed “Error Occured”.

When you compile? When you start web interview? When you import to HQ?
“Error occured” is this your interpretation of the error message? or is this the actual text?
Screenshot please.

The message mentions that you’ve used a macro $q1valid, but didn’t define it:
The name ‘q1valid’ does not exist in the current context.
Check the macros.

Oh that’s what i missed! Thanks! It worked now. Let me try it with our own set of questions.

it works fine with our own set of questions now. thanks a lot!