CASES Subcommand (LIST command)
CASES limits
the number of cases listed. By default, all cases in the active dataset
are listed.
- Any or all of the keywords below can be used. Defaults that are not changed remain in effect.
- If
LISTis preceded by aSAMPLEorSELECT IFcommand, case selections specified byCASESare taken from those cases that were selected bySAMPLEorSELECT IF. - If
SPLIT FILEis in effect, case selections specified byCASESare restarted for each split.
FROM n. Number of the first case to be listed. The default is 1.
TO n. Number of
the last case to be listed. The default is the end of
the active dataset. CASES 100 is interpreted as CASES TO 100.
BY n. Increment used to choose cases for listing. The default is 1.
Example
LIST CASES BY 3 /FORMAT=NUMBERED.
- Every third case is listed for all variables in the active dataset. The listing begins with the first case and includes every third case up to the end of the file.
-
FORMATdisplays the case number of each listed case.
Example
LIST CASES FROM 10 TO 20.
- Cases from case 10 through case 20 are listed for all variables in the active dataset.