LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous (more recent) messageNext (less recent) messagePrevious (more recent) in topicNext (less recent) in topicPrevious (more recent) by same authorNext (less recent) by same authorPrevious page (February 2010, week 4)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Thu, 25 Feb 2010 01:07:47 -0500
Reply-To:     Clark An <kuhasu@126.COM>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         Clark An <kuhasu@126.COM>
Subject:      Re: Data step Do loop to change the value of Macro Variable

1.e.g.

Thank you for the solution.

data mat2345; array x[2,3,4,5] x1-x120; retain n 0; do i=1 to 2; do j=1 to 3; do k=1 to 4; do l=1 to 5; n+1; ... x[i,j,k,l]=lag&n.(n); output; end; end; end; end; run;

If array can help me identify a variable easily,then how to treat lag function with macro variable?

2.What I want to do/get: 1)generate a series of variables. 2)put the value of a variable to macro varibles which can be used in new created varible's name. 3)lag&n.(x) in a loop without %do loop


Back to: Top of message | Previous page | Main SAS-L page