How to Suggest Better Question Names From Source LabelsThis article describes how to use a built-in QScript to remove untidy text from the ends of variable labels when the labels have been cut off in the data file:
To a state where the labels have been tidied by removing the extra truncated text:
Such truncation of data labels can occur in older data-processing software (e.g. Quantum) when there is a limit to the lengths of labels.
Truncation is identified by looking for patterns within sets of variables that have been grouped together. In Q, this is when the variables have been combined as a question.
Requirements
A data file loaded in Q.
This tool should only be applied to data where the labels look truncated, as in the example below. Applying it to data with labels that are already correct may have the effect of removing text unnecessarily.
Method
To run this QScript:
- Select Automate > Browse Online Library > Preliminary Project Setup > Remove Truncated Text from Variable Labels.
- A list of questions will be displayed. Select the questions you want to change from the list shown and click OK.
In the example below, the variable labels from this question have been truncated in the data file which results in a messy table presentation:
Applying this QScript results in a much neater table presentation:
If possible you should try to avoid having to use this tool by asking your data provider to prepare the data file according to the specifications linked at How to Format an SPSS File for Use in Q, and to ensure that there is no truncation of the variable labels in the SPSS data file.
Next
How to Use Scripts to Automate Data Checking and Cleaning
How to Check for Errors in Data File Construction
How to Identify Questions with Straight-Lining/Flat-Lining
How to Create New Variable(s) with Outliers Removed
How to Hide Uninteresting Data
How to Reverse Scales in Questions
How to Suggest Better Question Names From Source Labels