From: Arthur Tabachneck on 23 Dec 2009 13:21 Yusuf, One way would be to wrap your code in a SAS macro and then simply run the macro. E.g.,: %macro runit; %do i = 1 %to 181; proc reg data = in; model y = x&i.; quit; %end; %mend; %runit HTH, Art ------- On Wed, 23 Dec 2009 13:03:06 -0500, Yusuf Mohamedshah <zulsdad(a)GMAIL.COM> wrote: >Dear SAS-L'ers > >I have a data set with four observations. The first column is y and than a >series of columns labeled x1 to x181. I want to run a regression model such >that y = x1, y = x2 , y = x3 and so on till y = x181. So the question is how >can I call Regression Procedure 181 times to run the model. I want something >like: > >do i = 1 to 181; >proc reg data = in; >model y = x[i]; >quit; >run; >end; > >Any help would be appreciated. > >Thanks > >-- >Yusuf Mohamedshah
|
Pages: 1 Prev: data step rename Next: Can PROC GENMOD models be scored via PROC SCORE? |