Module 10: Multiple Regression Flashcards
What is PROC GLM?
Its a SAS procedure used for the analysis of variance and regression analysis.
Write the general syntax for PROC GLM.
proc glm data=dataset;
model y-var = list-of-x-var;
run;
How do you write an interaction term in PROC GLM?
var1 x var2
What does the class statement do in PROC GLM?
Specifies one or more categorical variables that you want to include in the regression
T/F: When the class variables are used, the parameter estimates are generated.
False: They are not generated. Need to use the SOLUTION model option.
T/F: By default SAS keeps the last level of the categorical variable as the reference group.
True
How do you specify another level of a categorical variable as the reference group?
Use the option REF = ‘ref-level in the class statement.
Ex. class eeogroup (ref = ‘1M’);
Given the following code, explain each line.
proc glm data=one;
1) class eeogroup;
2) model salary = eeogroup timeinjob othertime/solution;
3) output = out=oneout predicted=yhat residual= diff student =sigma
1) specifies eeogroup as categorical
2) specifies the model to use
3) Creates a new dataset called oneout that has the variables named yhat, diff, and sigma based on the outputs for predicted, residual, and student
Note: sigma is std. deviations