Introduction to SAS Research Computing Services Tutorial

Slide Note
Embed
Share

Learn about SAS availability, server vs. desktop vs. university edition, advantages and disadvantages, and different modes of SAS operation. Explore resources for training and reference, including information on Linux virtual lab, shared computing clusters, Windows desktop requests, on-campus computer labs, and SAS University Edition.


Uploaded on Sep 23, 2024 | 0 Views


Download Presentation

Please find below an Image/Link to download the presentation.

The content on the website is provided AS IS for your information and personal use only. It may not be sold, licensed, or shared on other websites without obtaining consent from the author. Download presentation by click this link. If you encounter any issues during the download, it is possible that the publisher has removed the file from their server.

E N D

Presentation Transcript


  1. Introduction to SAS IS&T Research Computing Services ithelp@bu.edu Tutorial Evaluation : http://rcs.bu.edu/eval

  2. Information Services & Technology 9/23/2024 Tutorial Logistics Please stay muted (SPACE bar to temporary unmute) Set Zoom to Speaker View and Side-By-Side mode Hide Non-video participants Submit questions in Chat, will answer during Q&A Presenter is Jack Chan (jack@bu.edu) Host is Aaron Fuegi (aarondf@bu.edu) Store received tutorial files under C:\intro2sas Tutorial divided into sections separated by Q&A Each section is a set of sample codes with a concept Tutorial Evaluation : http://rcs.bu.edu/eval hhttp://rcs.bu.edu/evalttp://rcs.bu.edu/eval

  3. Information Services & Technology 9/23/2024 Outline SAS Availability SAS Server vs. Desktop vs. University Edition SAS Full Screen Mode vs. Batch Mode Sample program about your SAS install (mysas.sas) Basic SAS program layout (lab1.sas) SAS with external raw data file (lab2.sas) Create and save permanent SAS dataset (lab3.sas) Recall and analyze saved SAS dataset (lab4.sas) Training And Reference Resources

  4. SAS Availability Linux Virtual Lab (scc-lite.bu.edu) General Computing Server - Open to Boston University community http://www.bu.edu/tech/services/cccs/desktop/computer-labs/unix/ Shared Computing Cluster (e.g. scc1.bu.edu etc.) Research Server - Requires project account on shared computing cluster https://www.bu.edu/tech/support/research/computing-resources/scc/ Windows Desktop Request via Medical Campus Office of Information Technology http://www.bumc.bu.edu/it/support/site-licensed/statistical/sas/ On Campus Computer Labs BU Common@ Mugar http://www.bu.edu/common/ Departmental Labs http://www.bu.edu/tech/services/cccs/desktop/computer- labs/departmental-labs-list/ SAS University Edition (Cloud/Local Virtual Machine) http://www.sas.com/en_us/software/university-edition.html

  5. SAS Server vs. Desktop vs. University Edition SAS Advantages Disadvantages Server Collaboration Automatic Backup Batch Processing Extra Computing Power Limited Storage Limited User Interface Shared Resources Requires Network Desktop User Friendly Interface Limited Computing Power Work Anywhere Collaboration Limitation Syntax Checking Lack Of Backup University Edition Free Runs on VM on Mac Runs on AWS Cloud Limited SAS modules Limited Computing Power Analysis Limitation

  6. SAS Full Screen Mode vs. Batch Mode Full Screen Mode - Use internal editor to create/modify program - Syntax checking (Desktop/University Edition) - Easier to debug - User friendly point and click Batch Mode - Use external/internal editor to create/modify program - Submit program and come back later for results - Concurrently running multiple SAS programs - Intermediate/Advance users

  7. Information Services & Technology 9/23/2024 SAS program about your SAS install (mysas.sas) How to document SAS codes Starts with asterisk * and ends with semicolon ; Return current installed SAS options proc options: * Return current SAS options; run; * Execute procedure; What modules are installed and license information proc setinit; * Show license and modules; run; * Execute procedure; All SAS statements end with semicolon Click Run -> Submit on top menu to execute codes 7

  8. Basic SAS program layout (lab1.sas) Options statement to set global options - Options stay current until reset or end of program Data statement to indicate start of dataset Input statement to define data structure fixed column - Default data type is numeric Datalines statement to indicate start of data Raw data embedded inside program Proc means procedure to calculate means Dataset is temporary in work , erase when SAS ends

  9. Information Services & Technology 9/23/2024 Modify SAS program lab1.sas (continued) Add an additional character variable gender Change input statement from: input id 1-2 height 4-5 weight 7-9; * Data definition; To: input id 1-2 height 4-5 weight 7-9 gender $11; * Data definition; Append value for gender at end of data in column 11 01 60 100 02 62 110 03 72 200 becomes becomes becomes 01 60 100 f 02 62 100 m 03 72 200 m Add 6th observation by click return after 5th observation 06 80 180 m Add frequency procedure proc freq; tables gender; * Calculate frequency tables; run; etc . etc . 9

  10. SAS with external raw data file (lab2.sas) Keep the options and title global options statements Remove datalines and embedded raw data Infile statement specify location of external raw data Infile points to previous created data file lab2.dat External raw data file contains fixed column data External data file can be shared by groups of people Lab2.dat contains 8 observations and 4 variables Same input statement define fixed column data Execute same proc means and proc freq procedures

  11. Create and save permanent SAS dataset(lab3.sas) Keep the options and title global options statements Libname to specify permanent dataset location Modify data statement for permanent dataset name Infile statement specify location of external raw data Infile points to previous created data file lab2.dat External raw data file contains fixed column data Lab2.dat contains 8 observations and 4 variables Same input statement define fixed column data No data analysis procedure (hence no output) Check Log window to verify dataset is created

  12. Recall and analyze saved SAS dataset (lab4.sas) Keep the options and title global options statements Keep the options and title global options statements Libname to specify permanent dataset location Libname inlib specify same location as outlib in lab3 Specify which dataset to use in procedure step Execute same proc means and proc freq procedures SAS converts raw data into SAS binary dataset Reading in binary SAS dataset save processing time Do more and faster with 7 lines of codes instead of 16

  13. Information Services & Technology 9/23/2024 Training And Reference Resources Within SAS - Help -> SAS Help and Documentation - Help -> Getting Started with SAS Software - Help -> Learning SAS Programming - Help -> SAS on the Web BU SAS Training Resources via E-Learning - http://www.bumc.bu.edu/it/support/site-licensed/statistical/sas/sas-e-learning/ Mathematics Department Tutoring Hours - Graduate students with statistics background Tutorial Evaluation : http://rcs.bu.edu/eval 13

Related


More Related Content