The LOGISTIC Procedure |
CLASS Variable Parameterization |
Consider a model with one CLASS variable A with four levels, 1, 2, 5, and 7. This section provides details of the possible choices for the PARAM= option.
Caution:PROC LOGISTIC initially parameterizes the CLASS variables by looking at the levels of the variables across the complete data set. If you have an unbalanced replication of levels across variables or BY groups, then the design matrix and the parameter interpretation might be different from what you expect. See the EFFECT parameterization in the following list for a specific example.
Three columns are created to indicate group membership of the nonreference levels. For the reference level, all three design variables have a value of . For instance, if the reference level is 7 (REF=’7’), the design matrix columns for A are as follows:
Design Matrix |
|||
---|---|---|---|
A |
A1 |
A2 |
A5 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameter estimates of CLASS main effects, using the effect coding scheme, estimate the difference in the effect of each nonreference level compared to the average effect over all 4 levels.
Caution:Unbalanced replication of levels across variables or BY groups might result in unexpected design matrices and parameter interpretations. For instance, suppose that in addition to the four-level variable A discussed earlier, you have another variable B with two levels, where the fourth level of A occurs only with the first level of B. If your model contains the effect A(B), then the design for A within the second level of B will not be a differential effect. In particular, the design will look like the following:
Design Matrix |
|||||||||
---|---|---|---|---|---|---|---|---|---|
A(B=1) |
A(B=2) |
||||||||
B |
A |
A1 |
A2 |
A5 |
A1 |
A2 |
A5 |
||
|
|
|
|
|
|
|
|
||
|
|
|
|
|
|
|
|
||
|
|
|
|
|
|
|
|
||
|
|
|
|
|
|
|
|
||
|
|
|
|
|
|
|
|
||
|
|
|
|
|
|
|
|
||
|
|
|
|
|
|
|
|
PROC LOGISTIC will then detect linear dependency among the last three design variables and set the parameter for A5(B2) to zero, resulting in an interpretation of these parameters as if they were reference- or dummy-coded. The REFERENCE or GLM parameterization might be more appropriate for such problems.
As in PROC GLM, four columns are created to indicate group membership. The design matrix columns for A are as follows:
Design Matrix |
||||
---|---|---|---|---|
A |
A1 |
A2 |
A5 |
A7 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameter estimates of CLASS main effects, using the GLM coding scheme, estimate the difference in the effects of each level compared to the last level.
Three columns are created to indicate group membership of the higher levels of the effect. For the first level of the effect (which for A is 1), all three design variables have a value of 0. The design matrix columns for A are as follows:
Design Matrix |
|||
---|---|---|---|
A |
A2 |
A5 |
A7 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
The first level of the effect is a control or baseline level. Parameter estimates of CLASS main effects, using the ORDINAL coding scheme, estimate the differences between effects of successive levels. When the parameters have the same sign, the effect is monotonic across the levels.
Three columns are created. The first represents the linear term (), the second represents the quadratic term (), and the third represents the cubic term (), where is the level value. If the CLASS levels are not numeric, they are translated into 1, 2, 3, according to their sorting order. The design matrix columns for A are as follows:
Design Matrix |
|||
---|---|---|---|
A |
APOLY1 |
APOLY2 |
APOLY3 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Three columns are created to indicate group membership of the nonreference levels. For the reference level, all three design variables have a value of 0. For instance, if the reference level is 7 (REF=’7’), the design matrix columns for A are as follows:
Design Matrix |
|||
---|---|---|---|
A |
A1 |
A2 |
A5 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Parameter estimates of CLASS main effects, using the reference coding scheme, estimate the difference in the effect of each nonreference level compared to the effect of the reference level.
The columns are obtained by applying the Gram-Schmidt orthogonalization to the columns for PARAM=EFFECT. The design matrix columns for A are as follows:
Design Matrix |
|||
---|---|---|---|
A |
AOEFF1 |
AOEFF2 |
AOEFF3 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
The columns are obtained by applying the Gram-Schmidt orthogonalization to the columns for PARAM=ORDINAL. The design matrix columns for A are as follows:
Design Matrix |
|||
---|---|---|---|
A |
AOORD1 |
AOORD2 |
AOORD3 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
The columns are obtained by applying the Gram-Schmidt orthogonalization to the columns for PARAM=POLY. The design matrix columns for A are as follows:
Design Matrix |
|||
---|---|---|---|
A |
AOPOLY1 |
AOPOLY2 |
AOPOLY5 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
The columns are obtained by applying the Gram-Schmidt orthogonalization to the columns for PARAM=REFERENCE. The design matrix columns for A are as follows:
Design Matrix |
|||
---|---|---|---|
A |
AOREF1 |
AOREF2 |
AOREF3 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Copyright © 2009 by SAS Institute Inc., Cary, NC, USA. All rights reserved.