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.

806 LOGISTIC REGRESSION<br />

CATEGORICAL Subcommand<br />

CATEGORICAL identifies independent variables that are nominal or ordinal. Variables that<br />

are declared to be categorical are automatically transformed to a set of contrast variables<br />

as specified on the CONTRAST subcommand. If a variable coded as 0 – 1 is declared as<br />

categorical, its coding scheme is given indicator contrasts by default.<br />

• Independent variables not specified on CATEGORICAL are assumed to be at least interval<br />

level, except for string variables.<br />

• Any variable specified on CATEGORICAL is ignored if it does not appear either after WITH<br />

on the VARIABLES subcommand or on any METHOD subcommand.<br />

• Variables specified on CATEGORICAL are replaced by sets of contrast variables. If the<br />

categorical variable has n distinct values, there will be n – 1 contrast variables generated.<br />

The set of contrast variables associated with a categorical variable is entered or removed<br />

from the model as a step.<br />

• If any one of the variables in an interaction term is specified on CATEGORICAL, the interaction<br />

term is replaced by contrast variables.<br />

• All string variables are categorical. Only the first eight characters of each value of a string<br />

variable are used in distinguishing between values. Thus, if two values of a string variable<br />

are identical for the first eight characters, the values are treated as though they were the same.<br />

Example<br />

LOGISTIC REGRESSION PASS WITH GPA, GRE, MAT, CLASS, TEACHER<br />

/CATEGORICAL = CLASS,TEACHER.<br />

• The dichotomous dependent variable PASS is regressed on the interval-level independent<br />

variables GPA, GRE, and MAT and the categorical variables CLASS and TEACHER.<br />

CONTRAST Subcommand<br />

CONTRAST specifies the type of contrast used for categorical independent variables. The interpretation<br />

of the regression coefficients for categorical variables depends on the contrasts<br />

used. The default is INDICATOR. The categorical independent variable is specified in parentheses<br />

following CONTRAST. The closing parenthesis is followed by one of the contrast-type<br />

keywords.<br />

• If the categorical variable has n values, there will be n –<br />

1 rows in the contrast matrix.<br />

Each contrast matrix is treated as a set of independent variables in the analysis.<br />

• Only one categorical independent variable can be specified per CONTRAST subcommand,<br />

but multiple CONTRAST subcommands can be specified.<br />

The following contrast types are available. See Finn (1974) and Kirk (1982) for further<br />

information on a specific type.<br />

INDICATOR(refcat) Indicator variables. Contrasts indicate the presence or absence of<br />

category membership. By default, refcat is the last category (represented<br />

in the contrast matrix as a row of zeros). To omit a category<br />

other than the last, specify the sequence number of the omitted category<br />

(which is not necessarily the same as its value) in parentheses<br />

after the keyword INDICATOR.

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

Saved successfully!

Ooh no, something went wrong!