Sentry Page Protection

**Data Analysis [9-15]**

**OUTPUT Statement**

You can also create an output data set for the analysis results.

Locate the CARS data set from the SASHelp library.

Now, let's compute the summary statistics on the MSRP variable.

Proc Means Data=SASHelp.cars;

Var MSRP;

Output Out=MSRP_Stat Mean=Mean STD=STD;

Run;

__Example__Locate the CARS data set from the SASHelp library.

Now, let's compute the summary statistics on the MSRP variable.

Proc Means Data=SASHelp.cars;

Var MSRP;

Output Out=MSRP_Stat Mean=Mean STD=STD;

Run;

The OUTPUT statement is similar to the one from Proc Univariate.

It tells SAS to create a new data set for the analysis results.

It tells SAS to create a new data set for the analysis results.

You can also specify the statistics to be computed by listing the statistics keywords:

The MSRP_Stat data set contains the mean and standard deviation as requested in the OUTPUT statement.

**Exercise**

Copy and run the NUM data set below:

The NUM data set contains a population of 10 data points.

A z-score is a measure of the number of standard deviation above or below the mean.

It can be calculated as:

z = x - µ/σ where

x = the value to be standardized

µ = the mean

σ = the standard deviation

Compute the z-score for each data points.

*Need some help?*

Fill out my online form.