The GEE Procedure (Experimental)

CLASS Statement

  • CLASS variables </ options>;

The CLASS statement names the classification variables to be used in the analysis. If the CLASS statement is used, it must appear before the MODEL statement.

Classification variables can be either character or numeric. CLASS levels are determined from the formatted values of the variables. Thus, you can use formats to group values into levels. For more information, see the discussion of the FORMAT procedure in the Base SAS Procedures Guide and the discussions of the FORMAT statement and SAS formats in SAS Formats and Informats: Reference.

You can specify the following options for classification variables:

DESCENDING
DESC

reverses the sort order of the classification variable. If you specify both the DESCENDING and ORDER= options, PROC GEE orders the categories according to the ORDER= option and then reverses that order.

ORDER=order-type

specifies the sort order for the categories of categorical variables. This ordering determines which parameters in the model correspond to each level in the data. When the default ORDER=FORMATTED is in effect for numeric variables for which you have supplied no explicit format, the levels are ordered by their internal values. Table 42.2 shows how PROC GEE interprets values of the ORDER= option.

Table 42.2: Sort Order for Categorical Variables

order-type

Levels Sorted By

DATA

Order of appearance in the input data set

FORMATTED

External formatted value, except for numeric variables that have no explicit format, which are sorted by their unformatted (internal) value

FREQ

Descending frequency count; levels that have the most observations come first in the order

FREQDATA

Order of descending frequency count, and within counts by order of appearance in the input data set when counts are tied

FREQFORMATTED

Order of descending frequency count, and within counts by formatted value (as above) when counts are tied

FREQINTERNAL

Order of descending frequency count, and within counts by unformatted value when counts are tied

INTERNAL

Unformatted value


For the FORMATTED and INTERNAL values, the sort order is machine-dependent. If you specify the ORDER= option in the MODEL statement and the ORDER= option in the CLASS statement, the former takes precedence.

For more information about sort order, see the chapter on the SORT procedure in the Base SAS Procedures Guide and the discussion of BY-group processing in SAS Language Reference: Concepts.