Hello, I am using SAS Studio Release 3.81. I'm learning basic SAS procedures for the first time. One of the methods is Two-Way ANOVA and now checking the model. For running the Two-Way ANOVA I use this code: proc anova data=athlete;
class lifestyle sex;
model systolic diastolic = lifestyle sex lifestyle*sex;
means lifestyle sex / duncan lines;
run; This particular model has two different responses, and this code gives me the ANOVA for each of the models. For model diagnostics, the book I'm using recommends this procedure: proc glm data=athlete;
class lifestyle sex;
model systolic = lifestyle sex lifestyle*sex;
output out=systolic p=yhat student=resid;
title1 'Two-Way ANOVAs for Lifestyle BP Study';
run;
proc gplot data=systolic;
plot resid*yhat / vref = 0;
title2 'Resid vs Y-hat';
plot resid*lifestyle / vref = 0;
title2 'Resid vs Lifestyle';
plot resid*sex / vref = 0;
title2 'Resid vs Sex';
run;
proc univariate data = systolic normal;
var resid;
probplot resid / normal (mu = est sigma = est) square;
title2 'Normal Test of Residuals';
run; I would then have to run this again for the diastolic response. The issue I'm having is that I can only run the diagnostics for one response at a time. The proc glm step only outputs one set of predicted yhat and residuals for the first predictor listed. Is there a way to output the predicted values and residuals for each response variable in the proc glm?
... View more