# How to replicate a question group based on a numerical answer

10 months 4 days ago - 10 months 4 days ago #161684 by ACa
ACa created the topic: How to replicate a question group based on a numerical answer
Hello everyone,

I apologize in advance if this question has already been answered elsewhere (I have unfortunately not been able to find an answer to my question in other answered questions).

I am doing a leadership survey among team leaders, who have to evaluate their employees with 7 questions. The sizes of each team vary and my participants are only the team leaders.

Each team leader will have to evaluate different employees with the same question group (comprised of the same 7 questions).

Is there a way to create a condition, where a numerical answer to a question (ex : how many employees do you have = 4), would automatically replicate the question group x number of times, each time for the evaluation of a different employee by the same person (their manager) ?

Thank you very much for your time and for any help / tips !!!
Last Edit: 10 months 4 days ago by ACa. Reason: subject was unclear

10 months 4 days ago - 10 months 4 days ago #161686 by Joffm
Joffm replied the topic: How to replicate a question group based on a numerical answer
Hello, Aca,
no. LS does not support dynamic loops.
You have to create as many question groups as the maximum number of employees evaluated by one person.
After the question "How many..." the question groups are displayed by relevance.
See: https://manual.limesurvey.org/images/d/de/Ls2_em_tailoring.lss

Group 1: always (hopefully each teamleader evaluates at least one employee)
Group 2: (number>1)
Group 3: (number>2)
Group 4: (number>3)
...

But IMHO you can do it easier.
Each survey only evaluates one employee.
1. question: Name or ID or teamleader
2. question: name or id of employee
3.-x. question: Evaluation

And in the endurl you can redirect to the survey itself. So it is not necessary to start the survey each time.

Advantage. Instead of having the data in several blocks you have the answers to one question in exactly one column.

Best regards
Joffm

Volunteers are not paid.
Not because they are worthless, but because they are priceless
Last Edit: 10 months 4 days ago by Joffm.
The following user(s) said Thank You: ACa