Welcome to the LimeSurvey Community Forum

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

End question group after 6 consecutive responses incorrect

More
3 years 2 months ago #229191 by HelenNorris
Please help us help you and fill where relevant:
Your LimeSurvey version: [see right hand bottom of your LimeSurvey admin screen] LimeSurvey Cloud version 3.28.13
Own server or LimeSurvey hosting: LimeSurvey hosting
Survey theme/template:
==================
(Write here your question/remark) Hi, I'm new to LimeSurvey.
I'm struggling to see how I could implement a rule where in a vocabulary test, if a participant gets 6 consecutive questions wrong, that section of the survey is ended.
It's important, because, otherwise the participants  (children) will have to try to answer too many questions that are too hard for them and they will tire.
There are already conditions set up for the vocabulary test where the start point varies according to age.
Any advice gratefully received- even if it's confirmation that it can't be done.
 

Please Log in to join the conversation.

More
3 years 2 months ago #229194 by tpartner
Can you provide a sample survey (.lss export)?

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.

Please Log in to join the conversation.

More
3 years 2 months ago - 3 years 2 months ago #229195 by Joffm
Please, send a lss export that we see the structure 

Joffm
Oh, Tony beat me. ;-)

Volunteers are not paid.
Not because they are worthless, but because they are priceless
Last edit: 3 years 2 months ago by Joffm.

Please Log in to join the conversation.

More
3 years 2 months ago - 3 years 2 months ago #229201 by HelenNorris
 Thank you for the quick response!

limesurvey_survey_995635 (1).lss

Is this right?

File Attachment:

File Name: limesurvey... (1).lss
File Size:273.37 KB
Last edit: 3 years 2 months ago by HelenNorris.

Please Log in to join the conversation.

More
3 years 2 months ago #229202 by HelenNorris
Thank you both for your speedy replies!

Please Log in to join the conversation.

More
3 years 2 months ago #229203 by holch
No. You need to attach the file. you can't just copy it into the editor.

There is no file attached, only the file name written as text.

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.

More
3 years 2 months ago #229204 by HelenNorris
Thank you- all very new to me. Ive just tried again.

Please Log in to join the conversation.

More
3 years 2 months ago #229207 by Joffm
Hi,
only 6 consecutive questions, 5 consecutive wrong answers, then one correct answer, again 5 wrong answers is fine?

I am thinking about a formula with different assessment values (0= correct, 1 = wrong)
So we have a question called "counter"
after each question there is an equation like
{counter=sum(counter,QCode,valueNAOK)*QCode.valueNAOK}
So, if the answer is wrong, the counter is raised by 1 and multiplied by 1
But if the answer ist correct, everything is multiplied by 0 and the counter is 0.

The questions get a relevance equation beside the age:  "counter<6"
This is a very rough idea. I will try it later.

Some other words:
Please revise your question types. To display a text (like "Let's start", etc.) use a question of type "text display", not "short text"
And better to use Expression Manager to enter the relevance equation than the "Condition Builder".
Just type AgeYears<=13 into the "relevance equation" field.

And I saw that your three questions regarding age are not validated.
With a birthdate of 2015, I can enter an agegroup of 11 and an Age of 13.

Joffm
 

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

Please Log in to join the conversation.

More
3 years 2 months ago #229226 by Joffm
This - above - idea works.
But you will need two more equations for each of your test questions.

Here is a different idea:
Create in the first group a (hidden) question of type "short text" (counter). This will be the container for the results.
Now, after each test question add a (hidden) question of type "equation" with this
{counter=join('#',V11.valueNAOK,V12.valueNAOK,V13.valueNAOK,V14.valueNAOK,V21.valueNAOK,V22.valueNAOK,V23.valueNAOK,V24.valueNAOK,V31.valueNAOK,V32.valueNAOK,V33.valueNAOK,V34.valueNAOK,'#')}

Here only four questions of each age group.

In the question "counter" you join the assessment values of all questions.
Answering the questions "wrong", "right", "right", "wrong", "wrong", "wrong" will give a result like
#011000#

In my small example I leave the test after three consecutive "wrongs"
Meaning: If the above string #011000# contains "000" there are three consecutive "wrongs".

Now you can set the relevance equation of the questions to
(AgeYear le 13 AND strpos(counter,"000")==0)
resp.
(AgeYear le 15 AND strpos(counter,"000")==0)
(AgeYear le 17 AND strpos(counter,"000")==0)


Proceed, as long there is no "000"
About "strpos" read the manual about "implemented functions"
[url] www.limesurvey.org/manual/ExpressionScri...mplemented_functions [/url]

Here a sample survey.
 

File Attachment:

File Name: limesurvey...8576.lss
File Size:56.25 KB


My other idea I will show later

Joffm

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

Please Log in to join the conversation.

More
3 years 2 months ago #229249 by Joffm
And here a different solution
Remember: Assessment values are reversed, right = 0, wrong = 1

 

File Attachment:

File Name: limesurvey...7459.lss
File Size:63.15 KB


But to be honest: I am not so happy with these solutions.
You may change your approach, saying
"all wrongs in this series of first section", age <14
"5 wrongs in this series of second section", age<16
Then split the third section into 6 parts, after each
"5 wrongs in this part".
This would be much easier to calculate.

Joffm

 

Volunteers are not paid.
Not because they are worthless, but because they are priceless
The following user(s) said Thank You: HelenNorris

Please Log in to join the conversation.

More
3 years 1 month ago #230189 by HelenNorris
Thank you very much indeed for your time and thoughts on this.
Apologies for the delay in replying- it has taken me a while to get my head around this.
I went with your second option because I understood it the best (!) and have added all the additional 90 equation questions plus the relevance equations for the 90 vocab questions. And it still doesn't work!
What did I do wrong?

I'll attach my revised survey.

Please Log in to join the conversation.

More
3 years 1 month ago #230190 by HelenNorris
 

File Attachment:

File Name: limesurvey...5635.lss
File Size:274.11 KB


Revised survey attached. Many thanks.

Please Log in to join the conversation.

More
3 years 1 month ago #230198 by Joffm
Sorry, Helen,
but there is nothing in it.
The relevance equation only selects the start point.

But where do you count the wrong answers?

You see the provided sample survey with the "counter" and the relevance equation ...strpos(counter,"00000") (for five consecutive wrongs) works without problem.

Joffm

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

Please Log in to join the conversation.

More
3 years 1 month ago #230274 by HelenNorris
Hi Joffm,

Thank you for your patience. This has been a bit of a learning curve for a technophobe like me.

I went over your dummy survey several times to see where I had gone wrong.
Because it might help others who are struggling like me, I list the mistakes I made:-

I needed the relevance equation in both the vocabulary questions AND in the vocabulary equation questions. Maybe obvious to most, but wasn't to me.
I noticed you created the 'counter' in the 'A bit about you' group, whereas I had put it in the vocabulary section, so I moved it. I don't know whether this would have made a difference.
I FINALLY noticed that the relevance equation you created referred to AgeYear whereas in my survey, the question code was AgeYears, so no wonder it didn't work.
I also noticed that there were differences in the syntax in the relevance equation in the dummy survey, compared to your message (differences in brackets, " versus ' , AND versus and ). I don't know enough about coding to know whether this made a difference or not.

But it finally works. Hurrah! I'm off to have a glass of wine and a lie-down.
Many thanks, again, from an exhausted mature PhD student.

I hope my errors help somebody else, some day. 

Please Log in to join the conversation.

Moderators: tpartnerholch

Lime-years ahead

Online-surveys for every purse and purpose