- If you downloaded a compressed file (one with a .gz or .zip extension) you will need to use Winzip or a similar file compression utility to uncompress or "extract" the file to its original size and default filename.
- If you downloaded an SPSS Portable file you should rename the uncompressed file so that the main part of the name is no more than 8 characters long and has an extension of ".por", e.g., sp6542.por
You can now open and begin to work with the correctly named SPSS portable format file.
- If you downloaded an SPSS setup file you should rename the uncompressed file so that the main part of the name is no more than 8 characters long and has an extension of ".sps", e.g., sp9954.sps
- If you downloaded a plain Data file you should rename the uncompressed file so that the main part of the name is no more than 8 characters long and has an extension of ".txt", e.g., da6542.txt
This will enable SPSS to recognize it as a plain ASCII text file. To access a plain text data file in SPSS you will need to utilize an SPSS setup file. (See below.)
How do I use the "SPSS setup" file I downloaded from ICPSR?
The SPSS setup file (also known as "data definitions statement" or "syntax") consists of a series of SPSS commands and information about the variables in the data file. The purpose of the setup file is to create a useable SPSS data file from the plain data file by defining all the data variables used in the file and then reading in the actual numeric data observations contained in the plain data file. This is necessary because the plain data file has insufficient internal information to identify individual variables and variable characteristics to external software packages.
1. Open up the SPSS setup file by starting your SPSS software and clicking File/Open/Syntax. Then go to the folder where you downloaded the SPSS setup file and open the file.
2. You can now edit the commands and other information contained in this file. In most cases you will need to make only two changes before running the commands contained in the file:
- First you will need to edit the command that tells SPSS where the data file is located on your computer. Look for the following lines near the top of the file:
FILE HANDLE DATA / NAME="file-specification"
DATA LIST FILE=DATA
Change these two lines to the following single command:
DATA LIST FILE="file-specification"
where file-specification is the full path to the data file on your computer, e.g.,
DATA LIST FILE="c:\users\da6542.txt"
Be sure to leave in the quotation marks. Also leave in any slashes you find after the DATA LIST command.
- Now go clear to the bottom of the file and add the following command if it is not there already:
EXECUTE.
Be careful to include the period after execute. Without the execute command the setup file will not run.
3. Once you have made these changes you are ready to run the setup file. Click on Run/All within the syntax editor window. This will produce an output window. If the commands work properly the output window will show a summary of what you asked SPSS to do. When all the commands have been fully executed the resulting SPSS data file will appear in the SPSS Data Editor window. This process may take a minute or more for large or complex files. At this point you are ready to start working with the data. You can subset, sort, recode, analyze, and save the data according to your needs.
4. If SPSS encounters problems while attempting to run the setup file there will be error messages in the output window and you will need to troubleshoot the commands in the setup file. Data Services offers limited assistance with troubleshooting setup file errors. Feel free to contact us!