03-08-2017 06:03 PM
I have to set a multiple linear regression with continuous and categorical variables.
SAS uses the highest value of a categorical variable as the reference level. How can I change the reference level of a categorical variable?
Can I use CLASS statement with the REF OPTION (REF=FIRST) in the PROC REG or PROC GLM?
11-29-2017 02:18 PM
Can you use PROC GLMSELECT to perform a standard linear regression? I'm running into the same problem with the reference group for my categorical variables. Thanks!
11-29-2017 02:26 PM
You can create the dummy variables in many different ways and use PROC REG.
But otherwise I think you can, this is from the documentation and I'm going to guess the first three sentences are what you need?
The GLMSELECT procedure compares most closely to REG and GLM. The REG procedure supports a variety of model-selection methods but does not support a CLASS statement. The GLM procedure supports a CLASS statement but does not include effect selection methods. The GLMSELECT procedure fills this gap. GLMSELECT focuses on the standard independently and identically distributed general linear model for univariate responses and offers great flexibility for and insight into the model selection algorithm. GLMSELECT provides results (displayed tables, output data sets, and macro variables) that make it easy to take the selected model and explore it in more detail in a subsequent procedure such as REG or GLM.
11-29-2017 02:57 PM
You can use the REF= option in the CLASS statement in PROC GLM. PROC REG does not have a CLASS statement. See this note on the topic for many procedures.
Need further help from the community? Please ask a new question.