LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous messageNext messagePrevious in topicNext in topicPrevious by same authorNext by same authorPrevious page (December 2001, week 1)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Wed, 5 Dec 2001 10:19:47 -0500
Reply-To:     Paige Miller <paige.miller@KODAK.COM>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         Paige Miller <paige.miller@KODAK.COM>
Organization: Eastman Kodak Company
Subject:      Re: how to assign a value to a Macro variable in SAS/IML..?
Content-Type: text/plain; charset=us-ascii

There seems to be no reason at all to have a macro variable here. Instead of using macros, you could just use the command.

print num;

Perhaps your example is really more complicated than what you show, and perhaps there really is a reason to use macros with IML. I avoid using macros with IML because I don't usually see a reason to use them. IML has enough language constructs (IF, WHILE, DO etc) so that macros are rarely necessary.

Also, call symput does not work in IML.

ywr1 wrote: > > hi all, > please help me out. > how can i assign a value of numeric variable to a Mactro variable > in SAS/IML..? > > my codes are as follows. > > proc iml; > > num=3; > call symput('please','num'); > print "&please "; > > The output is num. > > what should i do to get output showing 3 without typing %let please=3..?

-- Paige Miller Eastman Kodak Company paige.miller@kodak.com

"It's nothing until I call it!" -- Bill Klem, NL Umpire "When you get the choice to sit it out or dance, I hope you dance" -- Lee Ann Womack


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