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 (May 2012, week 1)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:   Mon, 7 May 2012 06:19:51 -0500
Reply-To:   "Data _null_;" <iebupdte@GMAIL.COM>
Sender:   "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:   "Data _null_;" <iebupdte@GMAIL.COM>
Subject:   Re: Setting missing values to 0 of many variables.
Comments:   To: Randy <randistan69@hotmail.com>
In-Reply-To:   <201205071057.q474gTFm018098@waikiki.cc.uga.edu>
Content-Type:   text/plain; charset=ISO-8859-1

proc stdize data=have out=want method=sum reponly missing=0; var _numeric_; *or other list; run;

On 5/7/12, Randy <randistan69@hotmail.com> wrote: > I have many variables that have missing value that I want to set to zero. > Is it possible to do it in a shorter way > > I wrote: > > data want ; set have ; > if VarA = 2 and VarB = . then VarB = 0 ; > if VarA = 3 and VarB = . then VarB = 0; > /* and so on*/ > run; > > VarA goes from 2-50 and I have 10 other Vars. Unfortunately they are not > numbered. > Randy >


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