Run a Matrix Coding query
Matrix coding queries enable you to cross-tabulate how content is coded.
What do you want to do?
- Understand matrix coding queries
- Create a Matrix Coding query using the Wizard
- Create a matrix coding query outside the Wizard
- Save the preview results as a node matrix
Understand matrix coding queries
You can use Matrix coding queries to ask a wide range of questions about patterns in the data and gain access to the content that shows those patterns. For example, you could use a Matrix Coding query to:
-
Compare what different demographic groups have said about an experience, an attitude or an issue
-
Compare terms used in different contexts
-
Compare attitudes
Refer to Move forward with queries and visualizations for more ideas about how you can use Matrix Coding queries to explore your data.
The resulting node matrix can be saved in your project as a query result or with your nodes in the Node Matrices folder.
When you are working a node matrix, you can:
-
Open a node from a matrix cell to see all the content coded at the cell (at both the row and column nodes)—double-click on a cell to open the node.
-
Apply shading to cells to make it easier to see patterns in the matrix
-
Change the information displayed in the matrix cells—for example number of sources coded or number of nodes coded
If you want to view the matrix as a chart, click the Chart tab. You can make changes to the chart type, title, labels, gridlines, and rotation—refer to Change the appearance or content of a chart for more information.
For more information on working with the results of a Matrix Coding query, refer to About node matrices and Work with the content of a node matrix.
Create a Matrix Coding query using the Wizard
-
On the Query tab, in the Create group, click Query Wizard.
The Query Wizard opens.
-
Click Cross-tabulate how content is coded, and then click Next.
-
On Step 2 and Step 3 of the Wizard, add the rows and columns you want to show in the matrix:
-
Click Add Selected Items to add a row/column that represents a specific node, source, content with a particular attribute value or other project item. For example, you could add a row/column that represents a thematic node or content coded to case nodes with the attribute value female.
-
Click Add Attribute Condition to add a row/column that represents all the sources or nodes that meet specific attribute value criteria. For example, you could add a row/column that represents all nodes within the classification person, where the attribute value for age is greater than 40.
-
On Step 4 of the Wizard, choose whether you want to search text in all your sources, or restrict the search to selected items or folders.
-
On Step 5 of the Wizard, choose whether you want to run the query just once or add it to your project (and run it). If you choose to add it to your project, you must enter a name. You can optionally enter a description.
-
Click Run.
The query is executed and the results are displayed in Detail View.
NOTE If you want to use Matrix Coding query features that are not available via the wizard—for example, show set members on separate rows/columns—you can add the query to your project and update it later. If you are familiar with NVivo queries, you may prefer to create the query outside the Wizard.
Create a matrix coding query outside the Wizard
If you are not familiar with NVivo queries, you may want to create your Matrix Coding query using the Wizard—the Wizard guides you through the process of setting your query criteria. However, not all query features are available in the Wizard, so you may sometimes want to create your Matrix Coding queries outside the Wizard, as described below:
-
On the Query tab, in the Create group, click Matrix Coding.
The Matrix Coding Query dialog box opens.
-
On the Rows tab, define the rows of the matrix:
-
In the Define More Rows list, click the type of item you want to display in rows—click the Select button to select the item.
-
Click the Add to List button. The criteria is added to the Generate node matrix with rows box.
-
(Optional) From the By Any User list, you can select coding done by any user or choose only the coding done by specific users—click the Select button to select the users.
-
On the Columns tab, define the columns of the matrix:
-
In the Define More Columns list, click the type of item you want to display in columns—click the Select button to select the item.
-
Click the Add to List button. The criteria is added to the Generate node matrix with columns box.
-
(Optional) From the By Any User list, you can select coding done by any user or choose only the coding done by specific users—click the Select button to select the users.
-
On the Node Matrix tab, create your search criteria:
-
In the Search for content of rows list, select a coding search operator such as AND. If you chose the NEAR or PRECEDING Content, you can specify the options for proximity and retrieval. For more information about the operators, refer to Combine criteria in queries.
-
Under Collection Display Options, you can specify how collections (sets and Search Folders) should be represented in the matrix results. By default, each collection is represented by a Single Row or Single Column (the members of the collection are not displayed). Select Multiple Rows or Multiple Columns if you want to show each member separately.
-
In the Name Display box, select whether you want to display just the project item name or include the hierarchical name in the matrix results.
-
(Optional) Set the scope of your query:
-
From the In list, select the items you want to include in the query. For example, search all sources or selected nodes.
-
From the Where list, you can specify to search project items created and/or modified by any or selected users.
-
Click Run.
NOTE
-
To save the Matrix Coding query, click the Add to Project check box and enter the name and description (optional) in the General tab.
-
If you include an 'aggregate' node in the scope of a query, content coded at the node and all its direct children will be included in the query results—refer to Aggregate nodes for more information.
-
To rearrange the items in the Generate node matrix with rows/columns box:
-
Use the arrow buttons to change the order of columns. Select an item from the column list and click the required arrow button.
-
To delete all items in the column list, click Clear.
-
To delete an item in the column list, select the item, click Remove.
Save the preview results as a node matrix
You can save the preview results as a node matrix in your project—either in the Results folder or Node Matrices folder.
This is useful when you want to keep a record of the coding in your project at a particular point in time.
To save the preview results as a new node matrix:
-
Click on the query results in Detail View.
-
On the Query tab, in the Actions group, click Store Query Results.
The Store Query Results dialog box opens.
-
Enter a name and description.
-
Click OK.
NOTE
-
By default new node matrix is created in the Results folder, unless you choose another location. Refer to Manage query results (Understand the Results Folder) for more information.
-
You can choose to save the results in your project before you run the query—by setting your preferences on the Query Options tab in the Matrix Coding Query dialog box.