Procedure features: |
PROC TRANSPOSE statement option:
|
|
This example performs a default transposition and uses no subordinate
statements.
|
options nodate pageno=1 linesize=80 pagesize=40; |
|
data score;
input Student $9. +1 StudentID $ Section $ Test1 Test2 Final;
datalines;
Capalleti 0545 1 94 91 87
Dubose 1252 2 51 65 91
Engles 1167 1 95 97 97
Grant 1230 2 63 75 80
Krupski 2527 2 80 76 71
Lundsford 4860 1 92 40 86
McBane 0674 1 75 78 72
; |
|
proc transpose data=score out=score_transposed;
run; |
|
proc print data=score_transposed noobs;
title 'Student Test Scores in Variables';
run; |
|
Student Test Scores in Variables 1
_NAME_ COL1 COL2 COL3 COL4 COL5 COL6 COL7
Test1 94 51 95 63 80 92 75
Test2 91 65 97 75 76 40 78
Final 87 91 97 80 71 86 72
| |
Copyright © 2010 by SAS Institute Inc., Cary, NC, USA. All rights reserved.