- Posts: 1
- Thank you received: 0
Welcome to the LimeSurvey Community Forum
Ask the community, share ideas, and connect with other LimeSurvey users!
Random subset of matrix questions
- lipflip
- Topic Author
- Offline
- New Member
Less
More
5 years 5 months ago #176049
by lipflip
Random subset of matrix questions was created by lipflip
Is it (and how) possible to randomly draw a subset of 10 questions from a matrix question with 20 questions for each participant and have only these questions presented/answered?
The topic has been locked.
- tpartner
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 10099
- Thank you received: 3589
5 years 5 months ago - 5 years 5 months ago #176073
by tpartner
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Replied by tpartner on topic Random subset of matrix questions
You can randomize the sub-question order and then use relevanceStatus in the sub-question relevance equations.
- manual.limesurvey.org/Expression_Manager#Access_to_Variables
So if, for example, you have a question code "Q1" and ten sub-questions with codes "SQ001, SQ002..." and you wanted to show 5 random sub-questions, the relevance equations would be as follows.
SQ001:
SQ002:
SQ003:
- manual.limesurvey.org/Expression_Manager#Access_to_Variables
So if, for example, you have a question code "Q1" and ten sub-questions with codes "SQ001, SQ002..." and you wanted to show 5 random sub-questions, the relevance equations would be as follows.
SQ001:
Code:
sum(Q1_SQ002.relevanceStatus, Q1_SQ003.relevanceStatus, Q1_SQ004.relevanceStatus, Q1_SQ005.relevanceStatus, Q1_SQ006.relevanceStatus, Q1_SQ007.relevanceStatus, Q1_SQ008.relevanceStatus, Q1_SQ009.relevanceStatus, Q1_SQ010.relevanceStatus) LT 5
SQ002:
Code:
sum(Q1_SQ001.relevanceStatus, Q1_SQ003.relevanceStatus, Q1_SQ004.relevanceStatus, Q1_SQ005.relevanceStatus, Q1_SQ006.relevanceStatus, Q1_SQ007.relevanceStatus, Q1_SQ008.relevanceStatus, Q1_SQ009.relevanceStatus, Q1_SQ010.relevanceStatus) LT 5
SQ003:
Code:
sum(Q1_SQ001.relevanceStatus, Q1_SQ002.relevanceStatus, Q1_SQ004.relevanceStatus, Q1_SQ005.relevanceStatus, Q1_SQ006.relevanceStatus, Q1_SQ007.relevanceStatus, Q1_SQ008.relevanceStatus, Q1_SQ009.relevanceStatus, Q1_SQ010.relevanceStatus) LT 5
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Last edit: 5 years 5 months ago by tpartner.
The following user(s) said Thank You: DenisChenu
The topic has been locked.
- tpartner
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 10099
- Thank you received: 3589
5 years 5 months ago #176109
by tpartner
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Replied by tpartner on topic Random subset of matrix questions
Correction, after further testing, it seems that this method does not work within arrays - only the first 5 subquestions are shown.
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.
- DenisChenu
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 13597
- Thank you received: 2487
5 years 5 months ago #176110
by DenisChenu
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
Replied by DenisChenu on topic Random subset of matrix questions
Maybe in 3.X only ? I think it work in 2.73 ?tpartner wrote: Correction, after further testing, it seems that this method does not work within arrays - only the first 5 subquestions are shown.
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The topic has been locked.
- jelo
- Offline
- Platinum Member
Less
More
- Posts: 5033
- Thank you received: 1257
5 years 5 months ago #176113
by jelo
The meaning of the word "stable" for users
www.limesurvey.org/forum/development/117...ord-stable-for-users
Replied by jelo on topic Random subset of matrix questions
I wasn't aware that relevanceStatus is working with subquestions at all
Was that available in old LTS as well? Or introduced later?
Was that available in old LTS as well? Or introduced later?
The meaning of the word "stable" for users
www.limesurvey.org/forum/development/117...ord-stable-for-users
The topic has been locked.
- DenisChenu
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 13597
- Thank you received: 2487
5 years 5 months ago #176125
by DenisChenu
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
Replied by DenisChenu on topic Random subset of matrix questions
I think relevanceStatus is related to EM know value : EM know only subquestion for array (for example : Q01.question didn't work and Q1_SQ1.question show the subquestion of SQ1 in question Q1).jelo wrote: I wasn't aware that relevanceStatus is working with subquestions at all
Was that available in old LTS as well? Or introduced later?
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The topic has been locked.
- limeluis99
- Offline
- New Member
Less
More
- Posts: 1
- Thank you received: 0
5 years 4 months ago #177585
by limeluis99
Replied by limeluis99 on topic Random subset of matrix questions
Hi,
in 3.15.5 I get only the last five subquestions. Is there any other possibility to randomly select a subset of subquestions from an array question?
Best, Luis
in 3.15.5 I get only the last five subquestions. Is there any other possibility to randomly select a subset of subquestions from an array question?
Best, Luis
The topic has been locked.