This example creates an output data set that
contains summary statistics
for the numeric variables that are compared.
|
libname proclib 'SAS-library'; |
|
options nodate pageno=1 linesize=80 pagesize=40; |
|
proc sort data=proclib.emp95 out=emp95_byidnum;
by idnum;
run;
proc sort data=proclib.emp96 out=emp96_byidnum;
by idnum;
run; |
|
proc compare base=emp95_byidnum compare=emp96_byidnum
outstats=diffstat noprint;
id idnum;
run; |
|
proc print data=diffstat noobs;
title 'The DIFFSTAT Data Set';
run; |
|
The DIFFSTAT Data Set 1
_VAR_ _TYPE_ _BASE_ _COMP_ _DIF_ _PCTDIF_
salary N 10.00 10.00 10.00 10.0000
salary MEAN 52359.00 53089.00 730.00 1.2374
salary STD 24143.84 24631.01 996.72 1.6826
salary MAX 92100.00 92100.00 2400.00 4.3864
salary MIN 29025.00 29025.00 0.00 0.0000
salary STDERR 7634.95 7789.01 315.19 0.5321
salary T 6.86 6.82 2.32 2.3255
salary PROBT 0.00 0.00 0.05 0.0451
salary NDIF 4.00 40.00 . .
salary DIFMEANS 1.39 1.38 730.00 .
salary R,RSQ 1.00 1.00 . .
| |
Copyright © 2010 by SAS Institute Inc., Cary, NC, USA. All rights reserved.