Actions

QS

Array filter/nl: Difference between revisions

From LimeSurvey Manual

No edit summary
(Updating to match new version of source page)
Line 6: Line 6:
'''Beschrijving'''
'''Beschrijving'''


Met een array-filter kun je een meerkeuzevraag gebruiken om te selecteren welke responses getoond worden in een vervolglijst, array of meerkeuzevraag.
The '''Array filter''' setting allows you to use any multiple choice question to select or set which responses are displayed in a subsequent list, array or multiple choice question.


<div class="simplebox">Vanaf versie 1.92 kunnen opeenvolgende vragen  gefilterd worden voor elk array vraagtype, inclusief:
<div class="simplebox">The subsequent questions can be filtered on any array question type, including:
*Meerkeuzevragen
*Multiple choice
*Meerkeuzevragen met opmerkingen
*Multiple choice with comments
*Meerdere korte vrije teksten
*Multiple short text
*Meervoudige numerieke invoer
*Multiple numeric
*Array (5 punten, 10 punten, Ja/Nee/Weet niet, Meer/Gelijk/Minder, met kolom)
*Array (5 point, 10 point, Yes/No/Unknown, Increase/Same/Decrease, Column)
*Array (Dubbele schaal, teksten, getallen)
*Array (Dual Scale, Text, Numbers)
*Rangschikken
*Ranking


Verder kunnen deze vraagtypes worden gefilterd.
Verder kunnen deze vraagtypes worden gefilterd.


De enige uitzondering is Array (met kolom), die kan andere vragen filteren, maar kan niet zelf worden gefilterd.</div>
The only exception is ''Array (Column)'', which can filter other questions, but not itself.</div>


'''Filter zetten'''
'''How to set a filter'''


Vul de vraagcode van een vraag met meerdere opties in om het te gebruiken als bron bij het instellen van het filter. Voorbeeld: als de vraagcode "Q1" is, vul dan "Q1" in het veld 'Array filter' of het veld 'Array Filter uitsluiting' in de  '''speciale instellingen''' van de vraag die je wilt filteren. Alleen de in vraag Q1 geselecteerde antwoordopties  zijn zichtbaar in de gefilterde vraag.
To set a filter, enter the question code of a multiple options question in the array filter box of the question you are currently editing. The respective question will be used as the source of information for the current question, the selected answers from the previous question being retrieved and used as answer options for the current question. '''For example''', if your source multiple option question code is "Q1", enter "Q1" into the 'Array Filter' box to start the filtering process of the answers. Only the answer options that are selected in question Q1 will be visible in the array_filter-ed question.


<div class="simplebox">Vanaf versie 1.92, kun je meerdere array_filter opties gebruiken bij een vraag. Gebruik dan een puntkomma om ze te scheiden</div>
<div class="simplebox">If you wish more questions to be filtered via this option, type the question codes in the box separated by semicolons (;). </div>


Bij het instellen van een Array filter is het ''verplicht'' dat de gebruikte vragen precies dezelfde antwoordenlijst hebben. Als de vragen niet dezelfde set van antwoorden en codes hebben, zal het filteren niet lukken.
{{Alert|Title=Attention|text=The subquestion codes used in the first question must coincide with the subquestion codes from the second one. Otherwise, the '''array filter''' function will not filter the answers to the first question. Check the below example to better understand how the whole system works.}}
 
<div class="simplebox">Vanaf versie 1.92, als Q2 subvragen heeft, die ontbreken in Q1, dan worden deze altijd getoond.</div>


'''Trapsgewijs'''
'''Trapsgewijs'''


Een Array filter werkt trapsgewijs; je kunt een vraag selecteren die een andere vraag filtert, die een andere vraag filtert, enz.
The selected options can be displayed in cascade. This means that you can select a question which filters another question, which filters another question, and so on.


'''Array filter voorbeeld'''
'''Array filter voorbeeld'''


Aanvink items: &lsquo;Een&rsquo;, &lsquo;Drie&rsquo; en &lsquo;Vier&rsquo; in de eerste vraag geeft de entries 'Een', 'Drie' en 'Vier' die getoond worden in de volgende vraag als die een array filter gebruikt
Let's take a look at the following example to better understand the power of this setting:
 
Vraag met meerdere keuzes
 
Code:Q1
 
Vraag: Welke dieren vind je leuk?
 
1 Kat
 
2 Hond
 
3 Zebra
 
Array 5 Punten
 
Code:Q2
 
Vraag: Geef op een schaal van 1 tot 5 aan hoe leuk je deze dieren vindt. 1 staat voor ''Ik vind het een beetje leuk'' en 5 is ''Ik vind het een erg leuk dier''
 
'''Array filter voorbeeld 2 - met Meerdere korte vrije teksten'''
 
<div class="simplebox">Deze functie is vanaf versie 1.92 beschikbaar.</div>
 
[[File:array_filter_with_multipe_short_text.jpg]]
 
De LimeSurvey groepsbestand voor de bovenstaande demo:


[[Media:limesurvey_group_32.lsg|limesurvey_group_32.lsg]]


'''Array filter voorbeeld 3 - Trapsgewijze Array Filters'''
<center>[[File:array_filter_with_multipe_short_text.jpg]]</center>


Deze enquête het gebruik van array_filter, array_filter_exclude, exclude_all_others en trapsgewijze array filters.


[[Media:ls2_cascading_array_filter.lss|ls2_cascading_array_filter.lss]]
In the screenshot from above, we got two questions. The first one is a ''multiple short text'' question type, while the second one is an ''array dual scale'' question type. The answers you provide in the first question will be listed in the second one. Technically, the answers you provide to the subquestions from the first question are filtered and displayed in the second question.


This example can be downloaded from the following link: [[Media:limesurvey_group_32.lsg|limesurvey_group_32.lsg]]. [[Question_groups_-_introduction#Import_a_question_group|Import this question group]] into your LimeSurvey installation.
</onlyinclude>
</onlyinclude>


[[Category:Question Settings/nl]][[Category:Advanced Question Settings/nl]]
[[Category:Question Settings]][[Category:Question Logic Settings]]

Revision as of 21:50, 7 March 2018


Array filter (array_filter)

Beschrijving

The Array filter setting allows you to use any multiple choice question to select or set which responses are displayed in a subsequent list, array or multiple choice question.

The subsequent questions can be filtered on any array question type, including:
  • Multiple choice
  • Multiple choice with comments
  • Multiple short text
  • Multiple numeric
  • Array (5 point, 10 point, Yes/No/Unknown, Increase/Same/Decrease, Column)
  • Array (Dual Scale, Text, Numbers)
  • Ranking

Verder kunnen deze vraagtypes worden gefilterd.

The only exception is Array (Column), which can filter other questions, but not itself.

How to set a filter

To set a filter, enter the question code of a multiple options question in the array filter box of the question you are currently editing. The respective question will be used as the source of information for the current question, the selected answers from the previous question being retrieved and used as answer options for the current question. For example, if your source multiple option question code is "Q1", enter "Q1" into the 'Array Filter' box to start the filtering process of the answers. Only the answer options that are selected in question Q1 will be visible in the array_filter-ed question.

If you wish more questions to be filtered via this option, type the question codes in the box separated by semicolons (;).
  The subquestion codes used in the first question must coincide with the subquestion codes from the second one. Otherwise, the array filter function will not filter the answers to the first question. Check the below example to better understand how the whole system works.


Trapsgewijs

The selected options can be displayed in cascade. This means that you can select a question which filters another question, which filters another question, and so on.

Array filter voorbeeld

Let's take a look at the following example to better understand the power of this setting:



In the screenshot from above, we got two questions. The first one is a multiple short text question type, while the second one is an array dual scale question type. The answers you provide in the first question will be listed in the second one. Technically, the answers you provide to the subquestions from the first question are filtered and displayed in the second question.

This example can be downloaded from the following link: limesurvey_group_32.lsg. Import this question group into your LimeSurvey installation.