What do you need help with?
Search the knowledge base, browse our resources, and visit our forum for more detailed information
Search the knowledge base, browse our resources, and visit our forum for more detailed information
Last updated: 15 Mar 2023
The Question Matrix response type allows users to create a group of questions that display in a matrix format, whereby each cell within the matrix represents a separate question. To use this response type, define the number of rows and columns you want in your matrix set and give each row and column a label or name. Each column can be a different question type. In the above screenshot, the first two columns are select-one questions, and the third column is a number question.
This response type only works when using Enketo, utilizing the Grid-theme layout. Forms are set to single page layout by default -- to change it, find the "layout" button in the formbuilder toolbar, select "grid-theme", save this change, and redeploy your form to make these changes live.
Enketo supports only up to 10
columns in versions less than 2.8.0
, up to 13
including and after 2.8.0
.
Go to your formbuilder and click on “Add question”
Select ‘Question Matrix’
Click on the gear icon in each column to set the question type.
Select the question type
Add the Column label & response label
Select the gear icon within ‘Row’ to define the row label
Alternatively, you can also build a Matrix Question in a XLSForm by following the instructions as outlined in the images below:
survey
type |
name |
label |
required |
|
---|---|---|---|---|
begin_kobomatrix |
M1 |
Items |
assets |
|
select_one yn |
Q1 |
Q1. Which assets do you have at home |
TRUE |
|
integer |
Q2 |
Q2. Number of assets |
TRUE |
|
end_kobomatrix |
choices
list_name |
name |
label |
---|---|---|
assets |
car |
Car |
assets |
bike |
Bike |
assets |
tv |
TV |
yn |
yes |
Yes |
yn |
no |
No |
settings
style |
---|
theme-grid no-text-transform |
This method uses begin_kobomatrix
,
end_kobomatrix
and kobo--matrix_list
.
Following the steps above, you should see the question matrix shown in the screenshot below (In Enketo only):
It is also possible to include relevant
and constraint
conditions within the
matrix as follows:
survey
type |
name |
label |
required |
|
relevant |
constraint |
---|---|---|---|---|---|---|
begin_kobomatrix |
M1 |
Items |
assets |
|||
select_one yn |
Q1 |
Q1. Which assets do you have at home |
TRUE |
|||
integer |
Q2 |
Q2. Number of assets |
TRUE |
${Q1} = ‘yes’ |
. > 2 |
|
end_kobomatrix |
Did you find what you were looking for? Was the information clear? Was anything missing?
Share your feedback to help us improve this article!
KoboToolbox is maintained by Kobo Inc.