|
|||
|
On Fri, 7 Nov 2008 10:55:40 -0500, Toby Dunn <tobydunn@HOTMAIL.COM> wrote:
>Ryan , > >Much depends on what you are trying to do, are you trying to put the >asterisk in the value of the variable, are you trying to put it next to >the value when you writ eit out to the log or some report? > >Perhaps this will get you a littl efurther along: > >Data One ; >SBP = 100 ; >Output ; >SBP = 166 ; >Output ; >SBP = 111 ; >Output ; >SBP = 169 ; >Output ; >Run ; > >Data _Null_ ; >Set One ; > >If SBP > 164 Then Put SBP= +(-1) '*' ; >Else Put SBP= ; >Run ; Or, if so inclined, put the conditionality inside a single PUT statement: Data _Null_ ; Set One ; Put SBP= +(-1) '*' +( (SBP > 164) -1 ) ' '; Run ; > > >On Fri, 7 Nov 2008 01:23:56 -0500, Ryan Richmond ><ryan.s.richmond@WMICH.EDU> wrote: > >>I would like to put an asterisk next to selected observations with an if/ >>then statement. So far, I'm not getting it to work out. >> >>data PBlood; >> set BloodP; >> if SBP>164 then put '*'; >> >>Thanks, Ryan. |
|
|
||||
|
||||
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Basic matrix operations in data steps and procedures | Dale McLerran | Newsgroup comp.soft-sys.sas | 0 | 12-12-2008 12:37 AM |
| Re: Question about efficient data extraction | Paul Dorfman | Newsgroup comp.soft-sys.sas | 0 | 06-05-2008 04:20 AM |
| Data Entry Online, Data Format, Data Conversion and Data EntryServices through Data Entry Outsourcing | Data Entry Outsourcing | Newsgroup comp.soft-sys.sas | 0 | 03-20-2008 12:00 PM |
| Re: Slpit data | Paul M. Dorfman | Newsgroup comp.soft-sys.sas | 0 | 08-29-2005 04:41 AM |
| Re: A case when the location of a format statement in a data step | Michael S. Zdeb | Newsgroup comp.soft-sys.sas | 0 | 07-07-2005 01:28 PM |