Base SAS 9.1 Procedures Guide, Volumes 1, 2, 3 and 4

Output Data Set

The TRANSPOSE procedure always produces an output data set, regardless of whether you specify the OUT= option in the PROC TRANSPOSE statement. PROC TRANSPOSE does not print the output data set. Use PROC PRINT, PROC REPORT, or some other SAS reporting tool to print the output data set.

Output Data Set Variables

The output data set contains the following variables:

Attributes of Transposed Variables

Names of Transposed Variables

PROC TRANSPOSE names transposed variables by using the following rules:

  1. An ID statement specifies a variable in the input data set whose formatted values become names for the transposed variables.

  2. The PREFIX= option specifies a prefix to use in constructing the names of transposed variables.

  3. If you do not use an ID statement or the PREFIX= option, then PROC TRANSPOSE looks for an input variable called _NAME_ from which to get the names of the transposed variables.

  4. If you do not use an ID statement or the PREFIX= option, and if the input data set does not contain a variable named _NAME_, then PROC TRANSPOSE assigns the names COL1, COL2, , COL n to the transposed variables.

Категории