Exporting Both Numeric Values and Choice Text to SPSS | XM Community
Skip to main content

Hi,
I have recoded the numeric answer values for one of my multiple choice questions. When I export the survey into SPSS, I only see the recoded values, and not the choice text. Is there a way to export both the recoded numeric values and the choice text into separate, adjacent columns?
For example, let's say that I was asking about favorite colors and recoded them to be Red=1; Blue=2; Yellow=3; Green=4.
I would like for one column to list the color names that my survey-takers chose (ex. Red, Green, Blue, Green, Yellow), and an adjacent column to list the recoded numeric values (ex. 1,4,2,4,3).
Thanks!

Hi there, I don't think it is possible to configure the SPSS exporter to include additional columns, though a Choice Text variable could be created in the dataset before or after the export is created.
To create the variable before the export is created and before data is collected, you could include the Choice Text as an Embedded Data field. This would create an additional column in the data that would be included in the SPSS export. The bottom of the Survey Flow might look something like the below:
AnswerTextEmbedding.png
To create the variable before the export is created and after data is collected, you could create a field by using Bucketing and naming the buckets after the Choice Text. This would create an additional column in the data that would be included in the SPSS export. The field editor might look something like the below:
ColorBucket.png
To create the variable after the export is created, you could use syntax to create an additional variable. The syntax to do that might look something like the below:
STRING ColorText(a20).
COMPUTE ColorText='null'.
IF (QColor=1) ColorText='Red'.
IF (QColor=2) ColorText='Blue'.
IF (QColor=3) ColorText='Yellow'.
IF (QColor=4) ColorText='Green'.
EXECUTE.


Leave a Reply