Example 7.1 Modifying All Observations in a Data Set in Place

Goal

Modify the values of existing variables in a data set without creating a new copy of the data set.

Example Features

Featured StepDATA step
Featured Step Options and StatementsMODIFY statement
Related TechniquePROC SQL, UPDATE clause
A Closer LookReviewing the CONTENTS Output for a Data Set Modified with the MODIFY Statement

Input Data Set

Data set DATACONFERENCE stores the schedule for one day of a conference. This data set is also the master data set in Example 7.2.


                                 DATACONFERENCE

  Obs  section    starttime talktime speaker              topic 1 Applications 8:00 AM 50 Brooks, Jason Customer Service 2 Data Mining 8:00 AM 50 Jones, Janet Direct Marketing 3 Statistics 8:00 AM 50 Thomas, Linda New ...

Get Combining and Modifying SAS® Data Sets: Examples Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.