Welcome to the LimeSurvey Community Forum

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

Randomise an especific subquestion into other questions

  • gabriela.garcia
  • gabriela.garcia's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
2 years 9 months ago #217646 by gabriela.garcia
Hi,
I have a question with 5 answer options (1,2,3,4,5). These question is followed by 2 other question options (if you answer 1 or 2 you go to question_a, if you answer 4 or 5 to question_b). I need to distribute those who answer 3 randomly between question_a and question_b. How can I do it?!

Thanks!
The topic has been locked.
  • tpartner
  • tpartner's Avatar
  • Away
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
2 years 9 months ago - 2 years 9 months ago #217648 by tpartner
Load a random number 1-2 in a hidden equation question (let's call it random1).

Then, relevance for question_a is:
Code:
Q1 == '1'
OR
Q1 == '2'
OR
(Q1 == '3' AND random1 == 1)

Relevance for question_b is:
Code:
Q1 == '4'
OR
Q1 == '5'
OR
(Q1 == '3' AND random1 == 2)

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Last edit: 2 years 9 months ago by tpartner.
The following user(s) said Thank You: DenisChenu
The topic has been locked.

Lime-years ahead

Online-surveys for every purse and purpose