Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!

Randomising 2 sets of answer options separately

  • AcuDan
  • AcuDan's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
2 years 2 months ago #233933 by AcuDan
Please help us help you and fill where relevant:
Your LimeSurvey version: 3.17
Own server or LimeSurvey hosting: Own
Survey theme/template: Custom
==================
Is it possible to randomise 2 sets of answer options at the same time? Here is an example:

I would like to randomise the order that the Yes and No options show. So in the image above, options 1 and 2 should randomise, and 3 and 4 should randomise. The Yes options would always be at the top, the No options below it, and Don't know would always stay at the bottom

Please Log in to join the conversation.

  • holch
  • holch's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 2 months ago #233941 by holch
Not out of the box. Might be possible with some custom javascript, maybe.

But I don't see that this is very helpful anyway. The radonization is there to avoid any bias because respondents click the first item. However, the first item is always "Yes", so the randomization won't help much, in my opinion.

Help us to help you!
  • Provide your LS version and where it is installed (own server, uni/employer, SaaS hosting, etc.).
  • Always provide a LSS file (not LSQ or LSG).
Note: I answer at this forum in my spare time, I'm not a LimeSurvey GmbH employee.

Please Log in to join the conversation.

  • Joffm
  • Joffm's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 2 months ago #233942 by Joffm
As @holch,
of course, you CAN do this by tayloring.
1. Create two questions of type "equation" to generate two random numbers.
eqRandom1: {if(is_empty(self),rand(1,2),self)}
eqRandom2: {if(is_empty(self),rand(1,2),self)}

2. Now, in your question you taylor the answer options
1: Yes - {if(eqRandom1==1,"Option 1","Option 2")}
2: Yes - {if(eqRandom1==1,"Option 2","Option 1")}
3: No - {if(eqRandom2==1,"Option 1","Option 2")}
4: No - {if(eqRandom2==1,"Option 2","Option 1")}
5: DK/NA

And in your analysis you have restructure a bit by the random numbers.

That's an easy solution without javascript.

Joffm ​​​​​​​​

Volunteers are not paid.
Not because they are worthless, but because they are priceless

Please Log in to join the conversation.

  • holch
  • holch's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 2 months ago #233947 by holch
Good solution with Limesurvey means.

A little bit dangerous because can't forget that you need to recode the answers depending on the random number, but besides that it should be easy to do so.

Help us to help you!
  • Provide your LS version and where it is installed (own server, uni/employer, SaaS hosting, etc.).
  • Always provide a LSS file (not LSQ or LSG).
Note: I answer at this forum in my spare time, I'm not a LimeSurvey GmbH employee.

Please Log in to join the conversation.

  • Joffm
  • Joffm's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 2 months ago #233948 by Joffm
To avoid "forgetting" here the other option, the usual one with the "multiple question" and the equation pushed in between.

A. You create your two random numbers.
B. You create a "multiple" question (M3) (which you hide) with the following subquestions
1: Yes - Option 1
2: Yes - Option 2
3: Yes - Option 1
4​​​​​: No - Option 1
5​​​​​: No - Option 2
​​​​​​​6​​​​​: No - Option 1
​​​​​​​
C: You create a question (eqM3) of type equation with the following:
{M3_1=if(eqRandom1==1,"Y","")}
{M3_2="Y"}
{M3_3=if(eqRandom1==2,"Y","")}
{M3_4=if(eqRandom2==1,"Y","")}
{M3_5="Y"}
{M3_6=if(eqRandom2==2,"Y","")}

D. Your final "single" question has the same codes as M3
1: Yes - Option 1
2: Yes - Option 2
​​​​​​​3: Yes - Option 1
4​​​​​: No - Option 1
5​​​​​: No - Option 2
​​​​​​​6​​​​​: No - Option 1
7. DK/NA

E: You set the array filter of this question to M3.

This way you will certainly remember to move the data
 

File Attachment:

File Name: limesurvey...9841.lss
File Size:24 KB


​​​​​​​Joffm

​​​​​​​

Volunteers are not paid.
Not because they are worthless, but because they are priceless

Please Log in to join the conversation.

Moderators: tpartnerholch

Lime-years ahead

Online-surveys for every purse and purpose