The following is an example of an SPS format file for a 6 question survey:
The Data List and Survey Data
Fixed Column Format Data
In the example above, the data is contained in a separate file (C:\Data\SampleData.dat) in a fixed column format.
The fixed column format is defined in the
DATA LIST section at the top of the .sps file. In this case the definition specifies that the response to question V1 is in column 1, the response to question V2 is in column 2, and so on:
The data file would be similar to the following. Each line represents the set of answers from a single respondent. In this example the first respondent answered "2" ("Sometimes") to question V1, "3" ("Often") to question V2, and so on:
With the fixed format, there must be no spaces at the start of the lines, otherwise these will be interpreted as responses.
For example if a space is incorrectly added to the start of the second line, then this would be treated as that person's response to question V1, with their real response to question V1 ("1" / "Never") incorrectly treated as their response to question V2:
Comma Separated Data
It is also possible for the data to be stored in a comma separated format, in which case the
DATA LIST section of the .sps file would be similar to the following:
When using a comma separated format, the
DATA LIST section simply specifies the order in which the responses appear in the data. In this case the responses are in the order V1, V2, V3, V4, V5, and then V6. The data file would be similar to the following:
It is also possible for the data itself to be stored inline in the .sps file. In this case the
DATA LIST section would be similar to the following:
The data itself appears at the end of the .sps file, enclosed in
BEGIN DATA and
END DATA statements:
IDs in Data
ID keyword in the
DATA LIST section is used to indicate that there are record numbers before each data row. For example:
The corresponding data section would be similar to the following:
VARIABLE LABELS section specifies the labels for each question. These appear in the SuperSTAR clients as the classification names.
Survey data in SuperWEB2:
VALUE LABELS section specifies the possible responses for each question. These labels display in the SuperSTAR clients as the classification values.
In this example, questions V1 to V4 have the same possible answers. The order in which the questions are specified in the
DATA LIST section is used to determine which questions are consecutive and are therefore implied by
V1 TO V4.
Survey Data in SuperWEB2: