Constructing Variables to Make Analysis Easy
In addition to the Basic Workflow For Checking and Cleaning a Project, it is also useful to create certain types of variables up-front that will facilitate additional analysis.
Pick One – Multi (e.g., likert scales, importance ratings)
Questions which contain ratings (e.g., ratings of importance, agreement, satisfaction) should be initially setup in Q as Pick One – Multi questions. It is often useful to have a number of additional variants of the data, such as numeric variables for computing means, and variables containing Top 2 Box Scores and separate versions of each individual item in the scale.
The most straightforward way to create such variables is usually as follows:
- Type the words create new variables into the Search features and data box in the top right of the Q window.
- Select the desired option from the QScripts and Rules section of the results. Commonly-useful options to choose are:
- Create New Variables - Flatten, which flattens a grid into a single column of numbers.
- Create New Variables - Create New Top 2 Category Variables (That is, Top 2 Boxes)
- Create New Variables - NPS Recoding
- Create New Variables - Midpoint Coding and Quantification
- Create New Variables - Case-Level Shares
To get a more in-depth understanding, refer to the Online Training tutorial on Multiple Response Questions.
Where Number - Multi questions have a small number of unique values, it is often useful to copy them and also represent them in a way that makes the categories visible. This can be done by:
- Select the variables in the question on the Variables and Questions tab.
- Change the Question Type setting to Pick One - Multi.
It is often useful to represent ranking data in multiple ways (e.g., percentages, top 3 ranks, means). See How to Analyze Ranking Data for detail on how to achieve this.
It is often useful to have two different version of Pick Any - Grid and Number - Grid questions: one version where the missing values are set at their defaults (i.e., people have missing values for options not seen) and another where the missing value are unchecked (if and as appropriate). For example, if the grid question shows occasions that different brands are consumed, and an earlier question in the study was used to filter which brands were shown in the grid question, it would be appropriate to un-check the missing values.
Coding text data
Importing coded data
Where coding has been done in another program, the best approach is usually to have it added to the data file. If you have the data in a different data file, the best approach is usually to:
- Get both data files as SPSS .sav data files. Note that if you have the data as a CSV or Excel file, you can convert it to an SPSS file using Tools > Save Data as SPSS/CSV File.
- Merge the data (see Merge Data Add Variables).
- Import the data into Q.
Often, coded data is not entered in the standard format for Pick Any data, so it is necessary to set its Question Type to Pick Any - Compact (see also Multi-punch/Multiple Response Questions Displaying as Grids).
Performing coding within Q
- Setting Up Your Data in Q for an overview of how to set up data in Q
- File Formats Supported by Q
- Manipulating data files
- Basic Workflow For Checking and Cleaning a Project
- Setting Statistical Assumptions When Setting Up Projects
- Weighting (Sample balancing)
- Advanced Data Tidying
- Exporting, Copying and Printing
- Updating Projects with New or Revised Data
- Converting Other Files Types into SPSS or CSV Data Files)