27.03.2013 Views

SPSS® 12.0 Command Syntax Reference

SPSS® 12.0 Command Syntax Reference

SPSS® 12.0 Command Syntax Reference

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

<strong>Command</strong>s 5<br />

before processing. All user specifications, including labels and data values, preserve<br />

upper and lower case.<br />

• Spaces can be added between specifications at any point where a single blank is allowed.<br />

In addition, lines can be broken at any point where a single blank is allowed. There are<br />

two exceptions: the END DATA command can have only one space between words, and<br />

string specifications on commands such as TITLE, SUBTITLE, VARIABLE LABELS, and<br />

VALUE LABELS can be broken across two lines only by specifying a + between string segments<br />

(see “String Values in <strong>Command</strong> Specifications” on p. 7).<br />

• The first word of a command can be abbreviated to a minimum of three letters provided<br />

no duplicates result. For example, AGGREGATE can be abbreviated to AGG, but<br />

COMPUTE can only be abbreviated to COMP to avoid confusion with COMMENT. A very<br />

small number of commands can duplicate an internal command when abbreviated to three<br />

characters (for example, LIST) and at least four characters should be used. For internal<br />

command structure, DATA LIST cannot be abbreviated.<br />

• If the first word of a multiple-word command has a duplicate (for example, FILE LABEL<br />

and FILE TYPE), the first word cannot be abbreviated.<br />

• All keywords after the first command word can be abbreviated to three characters. For<br />

example, ADD VAL LAB is a valid abbreviation for ADD VALUE LABELS, and EXA VAR=varlist<br />

is valid for EXAMINE VARIABLES=varlist. END DATA is an exception. You must spell both<br />

command keywords in full; END DAT is not a valid abbreviation for END DATA.<br />

• Three-character truncation does not apply to INFO command specifications. Spell out all<br />

keywords in full. For procedure names specified on INFO, spell out the first word in full<br />

and subsequent words through at least the first three characters.<br />

Running <strong>Command</strong>s<br />

You can run commands in either batch (production) or interactive mode. In batch mode, commands<br />

are read and acted upon as a batch, so the system knows that a command is complete<br />

when it encounters a new command. In interactive mode, commands are executed immediately,<br />

and you must use a command terminator to tell SPSS when a command is complete.<br />

Interactive Mode<br />

The following rules apply to command specifications in interactive mode:<br />

• Each command ends with a command terminator. The default command terminator is a<br />

period. It is best to omit the terminator on BEGIN DATA, however, so that inline data is<br />

treated as one continuous specification.<br />

• The command terminator must be the last nonblank character in a command.<br />

• <strong>Command</strong>s can begin in any column of a command line and continue for as many lines<br />

as needed. The exception is the END DATA command, which must begin in the first column<br />

of the first line after the end of data.<br />

• The maximum length of any command line is 80 characters, including the prompt and the<br />

command terminator.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!