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.

SELECT IF<br />

SELECT IF [(]logical expression[)]<br />

The following relational operators can be used in logical expressions:<br />

Symbol Definition Symbol Definition<br />

EQ or = Equal to NE or * Not equal to<br />

LT or < Less than LE or Greater than GE or >= Greater than or equal to *<br />

* On ASCII systems (for example, UNIX, VAX, and all PC’s) you can also use ~=;<br />

on IBM EBCDIC systems (for example, IBM 360 and IBM 370) you can also use ¬=.<br />

The following logical operators can be used in logical expressions:<br />

Example<br />

Overview<br />

Symbol Definition<br />

AND or & Both relations must be true<br />

OR or | Either relation can be true<br />

Not* Reverses the outcome of an expression *<br />

* On ASCII systems you can also use ~; on IBM EBCDIC systems<br />

you can also use ¬ (or the symbol above number 6).<br />

SELECT IF (SEX EQ ’MALE’).<br />

SELECT IF permanently selects cases for analysis based upon logical conditions found in the<br />

data. These conditions are specified in a logical expression. The logical expression can contain<br />

relational operators, logical operators, arithmetic operations, and any functions allowed in<br />

COMPUTE transformations (see COMPUTE and see “Transformation Expressions” on p. 37 in<br />

Volume I). For temporary case selection, specify a TEMPORARY command before SELECT IF.<br />

Basic Specification<br />

The basic specification is simply a logical expression.<br />

1478

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

Saved successfully!

Ooh no, something went wrong!