Date: Mon, 24 Jul 2006 10:24:31 -0400
Reply-To: Doug Rohde <drohde01@COMCAST.NET>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Doug Rohde <drohde01@COMCAST.NET>
Subject: Re: SCL Questions (hijacked thread)
I don't know if this is what Kevin had in mind, but this is the sort of
pseudo-function I use for protected division (or log, or sqrt, etc.):
%macro pdiv(newvar,num,denom,default = 0);
if &denom = 0 then &newvar = &default;
else &newvar = &num / &denom;
%mend;
Then of course I just call it like this:
data foo; set foo;
%pdiv(foo,var1,var2);
run;
I am interested to see how something like this is implemented in SCL.
Thanks.
Doug R
On Sat, 22 Jul 2006 11:47:40 -0400, Joe Whitehurst
<joewhitehurst@GMAIL.COM> wrote:
>Kevin,
>
>I have just been trying to douse some of the enthusiasm with which
>some MMMMs have been trying to promote the use of the Antiquated Macro
>Language, and I believe I have had some small success! Some of the
>MMMMs at least now mention SCL sort of as an afterthought when
>suggesting alternative solutions to questions posted by obvious
>neophytes. I understand and often use the Antiquated Macro Language
>to generate SCL code. But, I have not seen a datastep pseudo function
>created by the Antiquated Macro Language that I could not create with
>SCL. Do you have an example handy?
>
>Joe
>
>
>
>>
>> I don't personally agree with Joe's "religious persecution" of macro in
>> favor of SCL. I even know of a few a things that macro can do which SCL
>> cannot do as well (for instance, you can use macros to effectively
create
>> custom data step functions and even generate SCL code
|