Last active
August 29, 2015 14:12
-
-
Save joosti/642c18f16b5cecb3a261 to your computer and use it in GitHub Desktop.
SAS macro variables
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* variable assignments */ | |
| %let tableDir = C:\myProject\sas_output\; | |
| %let vars = roa roe asset_turn; | |
| /* create descriptive statistics */ | |
| proc means data=myDataset NOPRINT; | |
| output out=table1 mean= median= std= min= max= p25= p75= N=/autoname; | |
| var &vars; | |
| run; | |
| /* export to table_1.csv in &tableDir */ | |
| proc export data=table1 OUTFILE="&tableDir.table_1.csv" dbms=csv replace; | |
| run; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment