BookmarkSubscribeRSS Feed
deleted_user
Not applicable
Hello,
Is there an efficient way or an existing procedure within SAS to test whether the average residuals from an OLS model are the same between two subgroups of the estimation sample? Note that for a variaty of reasons, including indicators for subgroups in the model is not an option.

I have found an user generated macro, which however uses PROC IML, and I do not have that as part of my SAS installation. If I have to code the test from cratch, is there an alternative to PROC IML to get the matrix cross products (for the s.e. estimate of the difference in the residuals)?

Any thoughts or suggestions would be appreciated.
Thanks
2 REPLIES 2
Dale
Pyrite | Level 9
You are not clear about what it is that you want to compare - residual mean values or the variance of the residuals. You state that you want to test whether the "average residuals" are the same for subgroups of the sample. That sounds like a comparison of residual mean values.

Of course, residual mean value differences across subgroups is just differences in mean values across subgroups. And a test for mean differences is obtained when you include the group variable in a CLASS statement as well as on the right hand side of a model statement. But it sounds like you don't want to do that. Why?

Or am I misinterpreting your question? Do you want to examine differences in residual variance across groups?
deleted_user
Not applicable
Dale,
I want to compare the residual means, not variances. The reason I do not want to include the group variable in the CLASS statement and also in the model is because the means in residuals comparison needs to be made for many smaller sub-sets of the data and the model is too complex to be estimated over these smaller sub-sets.

Thanks

SAS Innovate 2025: Register Now

Registration is now open for SAS Innovate 2025 , our biggest and most exciting global event of the year! Join us in Orlando, FL, May 6-9.
Sign up by Dec. 31 to get the 2024 rate of just $495.
Register now!

What is ANOVA?

ANOVA, or Analysis Of Variance, is used to compare the averages or means of two or more populations to better understand how they differ. Watch this tutorial for more.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 2 replies
  • 1858 views
  • 0 likes
  • 2 in conversation