Help using Base SAS procedures

Collinearity Check

Posts: 0

Collinearity Check


I am new to this forum, had hard time figuring out how this could be done in SAS.

The code I am trying to run, regression analysis looks something like this:

Proc reg data = work.temp;
Model &Pred_var = &independent_var / stb tol vif Collin;
By segment;

I want to run a regression model such that it produces VIF values for each of the by Groups and checks the value of VIF.

Based on the value of VIF I should be able to Print if the regression model has collinearity(VIF > =5) or not(VIF <5).

And if there is collinearity then I should be able to give a rough idea of which variables might be correlated.

Your suggestions would be highly appreciated.

Thank you,

Super Contributor
Posts: 281

Re: Collinearity Check

You would have to write some macro code to pick out which by groups have VIF>=5 and then print only those. You can capture the VIF output into a SAS data set using ODS OUTPUT statements.

To get some idea of which variables might be correlated, I would use Principal Components Analysis on the independent variables.
Posts: 0

Re: Collinearity Check

Thank you so much for the reply .. ODS output works well !!

Next step I'll be proceeding with the variables that are correlated ...

again thanks,

Ask a Question
Discussion stats
  • 2 replies
  • 2 in conversation