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 (April 2007, week 3)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:   Mon, 16 Apr 2007 15:15:41 -0500
Reply-To:   "Huang, JS" <Huang.JS@PRINCIPAL.COM>
Sender:   "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:   "Huang, JS" <Huang.JS@PRINCIPAL.COM>
Subject:   Re: question about data step
Comments:   To: "Aspinall, Clifford G" <clifford.g.aspinall@PFIZER.COM>
In-Reply-To:   A<989E33E1BFEBB2439F85E9F37B12E8A508B5844B@groamrexm03.amer.pfizer.com>
Content-Type:   text/plain; charset="us-ascii"

This won't work since b1+mo12 is missing and hence sum(b1+mo12) is missing too as e in the following shows.

2586 data _null_; 2587 a=4; 2588 b=.; 2589 c=a+b; 2590 d=sum(a,b); 2591 e=sum(a+b); 2592 put c=; 2593 put d=; 2594 put e=; 2595 run;

c=. d=4 e=. NOTE: Missing values were generated as a result of performing an operation on missing values. Each place is given by: (Number of times) at (Line):(Column). 1 at 2589:6 1 at 2591:5 1 at 2591:10 NOTE: DATA statement used (Total process time): real time 0.00 seconds cpu time 0.00 seconds

-----Original Message----- From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of Aspinall, Clifford G Sent: Monday, April 16, 2007 3:09 PM To: SAS-L@LISTSERV.UGA.EDU Subject: Re: question about data step

sum(bl+mo12)

-----Original Message----- From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of Jane Sent: Monday, April 16, 2007 4:03 PM To: SAS-L@LISTSERV.UGA.EDU Subject: question about data step

Hi all

I had a question about data step. I have two variable (bl, mo12). mo12 has some missing variable.

I want to get bl+mo12, if mo12 is missing I just want to consider it as 0 instead of considering bl+mo12 as missing.

how can I do this only use one line command?

Thanks

jane

---------------------------------------------------------------------- LEGAL NOTICE Unless expressly stated otherwise, this message is confidential and may be privileged. It is intended for the addressee(s) only. Access to this E-mail by anyone else is unauthorized. If you are not an addressee, any disclosure or copying of the contents of this E-mail or any action taken (or not taken) in reliance on it is unauthorized and may be unlawful. If you are not an addressee, please inform the sender immediately.

-----Message Disclaimer-----

This e-mail message is intended only for the use of the individual or entity to which it is addressed, and may contain information that is privileged, confidential and exempt from disclosure under applicable law. If you are not the intended recipient, any dissemination, distribution or copying of this communication is strictly prohibited. If you have received this communication in error, please notify us immediately by reply email to Connect@principal.com and delete or destroy all copies of the original message and attachments thereto. Email sent to or from the Principal Financial Group or any of its member companies may be retained as required by law or regulation.

Nothing in this message is intended to constitute an Electronic signature for purposes of the Uniform Electronic Transactions Act (UETA) or the Electronic Signatures in Global and National Commerce Act ("E-Sign") unless a specific statement to the contrary is included in this message.

While this communication may be used to promote or market a transaction or an idea that is discussed in the publication, it is intended to provide general information about the subject matter covered and is provided with the understanding that The Principal is not rendering legal, accounting, or tax advice. It is not a marketed opinion and may not be used to avoid penalties under the Internal Revenue Code. You should consult with appropriate counsel or other advisors on all matters pertaining to legal, tax, or accounting obligations and requirements.


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