Question type: Multi question

From Catglobe Wiki
Jump to: navigation, search



Question type: Multi question

Question type: Multi question

Type

Number

General Description

This question is similar to a single question in that it consists of a question text and some answer options. The difference to a single question is that you for a multi question can choose multiple answer options. Each answer option is represented by a number; typically starting from 1 and increasing by 1 for each option thereafter.

A typical multi question would be ‘Which of these large European countries have you ever visited?’ with answer options ‘Germany’ (represented by a 1 on database), ‘Spain’ (represented by a 2 on database), and ‘Italy’ (represented by a 3 on database). An answer could e.g. be ‘1 and 3’ (meaning the user has visited Germany and Italy but never Spain).

Multi questions may also have open parts; that is an option which requires you to specify some additional text for the chosen option. An example of this could be ‘Which fruits do you like?’ (Name of question is 'Fruits') with answer options ‘Apples’ (=1), ‘Oranges’ (=2), ‘Others, please specify’ (=3). Let us imagine that the 3rd answer option is a partly open option, meaning that the user after having chosen it must write the fruits that he likes besides apples and oranges. In order to import these half-open options the user will need to place the open answer of an option in a separate column in the imported excel.

Import Group

Import Data (by selecting a questionnaire)

Business Rules

The name of the question to which you wish to import data must be the same as the imported files column header in order to ensure auto-mapping.

Since a user can answer more than one answer per question (in reality he can answer yes or no to each option) we cannot represent the answer with just one single number. Instead answers to multi questions are represented by a string of 0 and 1s, where 0 identifies a “no” answer and ‘1” a yes. The way we relate any 0 or 1 to an answer option is by its placement in a string. In the first example above where a user answered that he had been in option 1 and 3 out of 3 countries, it would translate into the string ‘101’.

When importing a string you must have the same number of 0 and 1s as there exists answer options.

If the question has open parts, each open part will be split to one column that can be mapped to during import. These columns work in the same way as text questions. If we try to import an open part of an answer option that is not selected, the open part will be ignored.

In order to automatically map to semi-open answer options we need to name the excel column the same name as the Multi Question + ‘_AO_’ + ‘n', where n is the option number. In example 2 above, where label was ‘Country’ and the open property was set for option 3, the name of the column in excel would need to be ‘Fruits_AO_3’.

Validation

  • String must consist of only 0s and 1s. If other numbers/characters than 0 and 1 are found in a column an error will be given during validation. Error type: ERROR (the import job will not be allowed to be executed).
  • The number of characters in the string must exactly match the number of possible answer options in the question else an error message stating ‘invalid length’ will be shown and System will give the advice on how many characters are required in this question. Error type: ERROR (the import job will not be allowed to be executed).
  • We will only be allowed to import open parts of questions to answer options that do exist, i.e. even though a the open property of a multi question has option 9 set as open then such an import will not be offered if there is no option 9 for the question.

Notes

A number of situations can happen when you import open and closed question parts and these are not logically related for a specific user

Situation 1: When importing only closed parts

  • Any open parts will be set to null.

Situation 2: When importing both open and closed parts

  • If the two are not logically related then the open part will not be imported.

Situation 3: When importing only open part

  • If open part does not fit with current closed parts then open part is ignored.
  • If closed part is null then closed part will be set to selected and open part then imported.