Monday, January 9, 2012

SAS: Exporting data

In the past, I have only used PROC EXPORT to export SAS data in non-SAS format (e.g. in Excel).  For example:  

proc export data=data_out
 outfile='C:\Clients\data_out.xls'
 dbms=excel
 replace;
run;

However, to my knowledge, value labels cannot be exported.  An easy work-around is to use ODS and save the data as a .csv file: 

ODS CSV file="C:\Clients\data_out.csv";
  proc print data=data_out label noobs;
  run;
ODS CSV close;

Additional ways of exporting SAS data can be found here:

No comments:

Post a Comment

Subscribe via email

Enter your email address:

Delivered by FeedBurner

Followers

google analytics