Data Step Processing [1-9]

h

Quick Review on Data Step

A data step is the code that creates a SAS data set.

Below is an example:

Data Profile;
Input Name $ Age;
Datalines;
Khan 28
Natalia 32
Tommy 29
Lee 34
;
Run;

Note: run the code on your SAS Studio to see the result.

The data step above contains an INPUT and DATALINES statement.

It creates the data set below:


Have you ever wondered how this data set is magically created in SAS?

In fact, SAS goes through two phases when creating the data set:

  • Compilation phase and
  • Execution phase

Let's look at each phase in detail.