Welcome to the LimeSurvey Community Forum

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

How to make sub-questions from a question?

  • ymca
  • ymca's Avatar Topic Author
  • Offline
  • Elite Member
  • Elite Member
More
4 years 1 month ago - 4 years 1 month ago #195572 by ymca
Hi,

I have a question with answers of "yes" and "no".
When a user choose "yes" I want him to get/see another question with some answers.
After he answer that question he will get 3 more questions one after another like this:
Code:
1. did you?
     a. no
     b. yes
             are you?
                    a. maybe
                    b. sure
                    c. probably
             is it ok?
                    a. maybe
                    b. sure
                    c. probably
                    d. not sure
             will you?
                    a. maybe
                    b. i can try
I've seen this but I don't understand how to make it work:
manual.limesurvey.org/Adding_answers_or_subquestions

LS Version 4.2+
Last edit: 4 years 1 month ago by ymca.
The topic has been locked.
  • Joffm
  • Joffm's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
4 years 1 month ago #195575 by Joffm
Replied by Joffm on topic How to make sub-questions from a question?
Hi,
what you show is a simple cascade of single punched questions, displayed one after the other by relevance.
Q1 (YES/NO)
Q2: Q1==YES
Q3: !is_empty(Q2)
Q4: !is_empty(Q3)

FYI:
There is a solution to display levelled multipunch questions, meaning the next level is displayed after selecting an option.


File Attachment:

File Name: limesurvey...4394.lss
File Size:52 KB


The first two questions in the example use the subquestion codes to define the level, the third question the position.

Joffm

And I do not see any relevance of the link you show.

Volunteers are not paid.
Not because they are worthless, but because they are priceless
The topic has been locked.
  • ymca
  • ymca's Avatar Topic Author
  • Offline
  • Elite Member
  • Elite Member
More
4 years 4 weeks ago #195603 by ymca
Thanks.

I see that it's a "multiple choice" and I need it to be "radio buttons" so that only 1 answer will be chosen.

LS Version 4.2+
The topic has been locked.
  • tpartner
  • tpartner's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
4 years 4 weeks ago #195611 by tpartner
Replied by tpartner on topic How to make sub-questions from a question?

I see that it's a "multiple choice" and I need it to be "radio buttons" so that only 1 answer will be chosen.

You will need to break it into several questions - you cannot select more than one radio in a single question.

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.
  • Joffm
  • Joffm's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
4 years 4 weeks ago #195615 by Joffm
Replied by Joffm on topic How to make sub-questions from a question?

I see that it's a "multiple choice" and I need it to be "radio buttons" so that only 1 answer will be chosen.

I know that.
This was just to show you something, if some day you are going to create a question like this.

And as we told you, you have to split it.
Easy, with relevance as I explained.

Joffm

Volunteers are not paid.
Not because they are worthless, but because they are priceless
The topic has been locked.
  • ymca
  • ymca's Avatar Topic Author
  • Offline
  • Elite Member
  • Elite Member
More
4 years 4 weeks ago - 4 years 4 weeks ago #195635 by ymca

tpartner wrote:

I see that it's a "multiple choice" and I need it to be "radio buttons" so that only 1 answer will be chosen.

You will need to break it into several questions - you cannot select more than one radio in a single question.


This is so confusing to me :unsure: (just a couple of hours ago I saw the "tree like numbers SQ1, SQ11...).
I've tried to make it with a tree but it gave me an error.

For the first question I do need "one radio in a single question".
this is my tree (I think this is the most complex part in the survey):
Code:
Q09: 
      A01: no (user who chooses this answer needs to jumps to "Q019")
      A02: yes (has 4 questions)
            A1: (user who chooses this answer needs to jumps to "Q010")
            A2: (user who chooses this answer needs to jumps to "Q010")
            A3: this answer has 4 questions (after he finishes to fill them, the survey will end for him)
                  Q1: this question has 15 answers
                  Q2: this question has 9 answers (multiple choice)
                        SA1:
                        SA2:
                        SA3:
                        SA4:
                        SA5:
                        SA6: this answer has 5 answers (multiple choice)
                        SA7:
                        SA8:
                        SA9:
                  Q3: this question has 18 answers (multiple choice)
                  Q4: this question has 2 answers (radio buttons)
                        SA11:  
                        SA12: this answer has the same 18 answers (multiple choice) as in "Q3"
            A4: this question has 2 answers (radio buttons)(after he finishes to fill them, the survey will end for him)
                  SA111:
                  SA112: this answer has the same questions and answers as in "A3"
 
 
(I will also need to use the "Q3" and "Q4" questions with their answers, later in the survey for other people that in "Q09" answered "A01" (here I guess LimeSurvey doesn't reuse the question so we need to use the "label set"?))

LS Version 4.2+
Last edit: 4 years 4 weeks ago by ymca.
The topic has been locked.
  • Joffm
  • Joffm's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
4 years 4 weeks ago - 4 years 4 weeks ago #195638 by Joffm
Replied by Joffm on topic How to make sub-questions from a question?
To bw honest, You confued us.
You do not want one levelled question.
What you want to do is simple branching

Q09: Yes/No
Axxx: relevance: Q09==Y, answer options "A1","A2","A3","A4"
Q1: relevance: Axxx=="A3"
Q2: relevance: Axxx=="A3"
SA6: relevance: Q2_SA6=="Y"
Q3: relevance: Axxx=="A3"
Q4: relevance: Axxx=="A3"
...

Q10: relevance: Axxx="A1" or Axxx="A2"
...

Now your homework is to translate your "tree" into a one-dimensional routing.

Joffm

Volunteers are not paid.
Not because they are worthless, but because they are priceless
Last edit: 4 years 4 weeks ago by Joffm.
The topic has been locked.
  • ymca
  • ymca's Avatar Topic Author
  • Offline
  • Elite Member
  • Elite Member
More
4 years 4 weeks ago #195670 by ymca

Joffm wrote: To bw honest, You confued us.
You do not want one levelled question.
What you want to do is simple branching

Q09: Yes/No
Axxx: relevance: Q09==Y, answer options "A1","A2","A3","A4"
Q1: relevance: Axxx=="A3"
Q2: relevance: Axxx=="A3"
SA6: relevance: Q2_SA6=="Y"
Q3: relevance: Axxx=="A3"
Q4: relevance: Axxx=="A3"
...

Q10: relevance: Axxx="A1" or Axxx="A2"
...

Now your homework is to translate your "tree" into a one-dimensional routing.

Joffm

So sorry.
I'm confused myself, didn't know what option to use in the system for that so I wrote all so I'll be the most clear I can be.
I'ts so simple when the survey is in front of me in the word document.
Is there a tutorial for doing the relevance thing?
I feel like you giving me keys but I don't know what vehicle to use.

LS Version 4.2+
The topic has been locked.
  • Joffm
  • Joffm's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
4 years 4 weeks ago #195671 by Joffm
Replied by Joffm on topic How to make sub-questions from a question?
Unfortunately the link to the sample surveys seems to be broken.

But question or group relevance is quite easy.

In each question you see a field "condition". (and also in groups)
Here you enter the condition, when a question is displayed.
By default this value is always "1", meaning "TRUE", so the question is displayed.
E.g. if you enter Q1==1, this question is only displayed if the respondents selected code 1 in question Q1.

So create your survey, and if there are more questions, don't hesitate to ask; but attach a lss export of it, that we can see your tries and maybe your errors..

Joffm

Volunteers are not paid.
Not because they are worthless, but because they are priceless
The topic has been locked.
  • ymca
  • ymca's Avatar Topic Author
  • Offline
  • Elite Member
  • Elite Member
More
4 years 4 weeks ago #195676 by ymca
Thanks you so much. I'll try to create them now.

LS Version 4.2+
The topic has been locked.
  • ymca
  • ymca's Avatar Topic Author
  • Offline
  • Elite Member
  • Elite Member
More
4 years 4 weeks ago - 4 years 4 weeks ago #195696 by ymca

Joffm wrote: Now your homework is to translate your "tree" into a one-dimensional routing.

What do you mean by that?
Instead of creating all of Q09 Q&A's in 1 column, I need to split them to only questions with 1 level of answers and connect all of them with the "relevance"?

Or can I create 1 question (I must choose "multiple choice type:M"?) and then all of my tree with the "relevance" in the "quick add" button?

LS Version 4.2+
Last edit: 4 years 4 weeks ago by ymca.
The topic has been locked.
  • ymca
  • ymca's Avatar Topic Author
  • Offline
  • Elite Member
  • Elite Member
More
4 years 4 weeks ago - 4 years 4 weeks ago #195697 by ymca
For example instead of this:
Code:
(list radio type:L)
Q1: Where did it happen?
 
SQ1:•  In my country (link country from "place of residence" question)
SQ2:•  In another country
            SQ11:o  List of countries (can I make here "list dropdown type:!"?)

I need to make it like this?
Code:
(list radio type:L)
Q1:Where did it happen?
 
A1:•  In my country (link country from "place of residence" question)
A2:•  In another country
add a new question:
Q2:List of countries (list dropdown type:!)(relevance if user chose "A2")
answers will be the countries names
Also, do I need "Assessment value" for linking the country the user chose in the start of the survey so it will appear in "SQ1" or "A1"?
Because I didn't see "relevance" for answers, just for questions.

LS Version 4.2+
Last edit: 4 years 4 weeks ago by ymca.
The topic has been locked.

Lime-years ahead

Online-surveys for every purse and purpose