***********************************************************; * Research Computing Services *; * Introduction to SAS *; ***********************************************************; ***********************************************************; * Import Data from an excel file *; * *; ***********************************************************; * Read more: ; * https://support.sas.com/documentation/cdl/en/acpcref/63184/HTML/default/viewer.htm#a003102096.htm ; * https://learnsascode.com/importing-excel-data-into-sas/ ; * Define a variable that can be used to specify a path for the input and/or output datasets; %let path=/usr/ktrn/SAS/Intro to SAS/Datasets; proc import datafile="&path/MedVisits.xlsx" out=visits dbms=xlsx replace; * Additional Options; datarow=2; /* data starting row */ sheet="MedVisits"; /* default - the first sheet */ range="MedVisits$A1:G20"; /* default - all rows and columns */ run; proc print data=visits; run;