The CLASS statement names the classification variables to be used in the model. Typical classification variables are Treatment
, Sex
, Race
, Group
, and Replication
. If you use the CLASS statement, it must appear before the MODEL
statement.
Classification variables can be either character or numeric. By default, class levels are determined from the entire set of
formatted values of the CLASS variables.
Note: Prior to SAS 9, class levels were determined by using no more than the first 16 characters of the formatted values. To revert
to this previous behavior, you can use the TRUNCATE option in the CLASS statement.
In any case, you can use formats to group values into levels. 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 adjust the order of CLASS variable levels with the ORDER=
option in the PROC GLIMMIX
statement.
You can specify the following REF= option to indicate how the levels of an individual classification variable are to be ordered
by enclosing it in parentheses after the variable name:
-
REF=’level’ | FIRST | LAST
-
specifies a level of the classification variable to be put at the end of the list of levels. This level thus corresponds to
the reference level in the usual interpretation of the estimates with PROC GLIMMIX’s singular parameterization. You can specify
the level of the variable to use as the reference level; specify a value that corresponds to the formatted value of the variable if
a format is assigned. Alternatively, you can specify REF=FIRST to designate that the first ordered level serve as the reference,
or REF=LAST to designate that the last ordered level serve as the reference. To specify that REF=FIRST or REF=LAST be used
for all classification variables, use the REF=
global-option after the slash (/) in the CLASS statement.
You can specify the following global-options in the CLASS statement after a slash (/):
-
REF=FIRST | LAST
-
specifies a level of all classification variables to be put at the end of the list of levels. This level thus corresponds
to the reference level in the usual interpretation of the estimates with PROC GLIMMIX’s singular parameterization. Specify
REF=FIRST to designate that the first ordered level for each classification variable serve as the reference. Specify REF=LAST
to designate that the last ordered level serve as the reference. This option applies to all the variables specified in the
CLASS statement. To specify different reference levels for different classification variables, use REF=
options for individual variables.
-
TRUNCATE
-
specifies that class levels be determined by using only up to the first 16 characters of the formatted values of CLASS variables.
When formatted values are longer than 16 characters, you can use this option to revert to the levels as determined in releases
prior to SAS 9.