SAS OnlineTutorback||next

Try It! Conditionally perform an action.

Creating HTML output? Read this first.
  1. Copy the program below and paste it into the Program Editor window (or issue the command copy sashelp.oltutor..source).
    data finance.totals;
       set finance.credit;
       DTotal+transaction;
    run;
    
    Modify the DATA step to create and sum the variable DTotal only when the value of Type is D. Otherwise, use the value of Transaction to create and sum the variable CTotal.

  2. Submit the DATA step and correct any errors, then print the data set.

    Return here and select Next.

Solution

back||next

Copyright © 2002 SAS Institute Inc., Cary, NC, USA.
All rights reserved.

Terms of Use & Legal Information | Privacy Statement