1 / 15

BMTRY 789 Introduction to SAS Programming

BMTRY 789 Introduction to SAS Programming. Lecturer: Annie N. Simpson, MSc. Syllabus. DEPARTMENT: Biostatistics, Bioinformatics, and Epidemiology PRINCIPAL INSTRUCTOR: A. Simpson, MSc. METHODS OF EVALUATION: Pass/No Pass (2 Credit Hours) Homework Assignments 70%

Download Presentation

BMTRY 789 Introduction to SAS Programming

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. BMTRY 789 Introduction to SAS Programming Lecturer: Annie N. Simpson, MSc.

  2. Syllabus • DEPARTMENT: Biostatistics, Bioinformatics, and Epidemiology • PRINCIPAL INSTRUCTOR: A. Simpson, MSc. • METHODS OF EVALUATION: Pass/No Pass (2 Credit Hours) Homework Assignments 70% Class Preparation and Participation 20% Group Presentation 10% • READINGS: Readings assigned for a class are expected to be read prior to that class session. • REQUIRED TEXT: Applied Statistics and the SAS Programming Language. Cody R.P. and Smith, J.K. (5th Edition) 2006. Prentice Hall, Upper Saddle River, NJ 07458. • WHEN OFFERED: Summer Semester, 12 weeks, Wed 10:00am-12:30pm BMTRY 789 Intro. To SAS Programming

  3. Syllabus (cont.) • METHODS OF EVALUATION: Pass/No Pass (2 Credit Hours) Class Preparation and Participation 20% • Homework (70%): : • Homework is the main method of evaluation (AND PRACTICE!) 7-9 HWS, 1 free miss, 4 “√-” or less = your pass is in jeopardy (depending on attendance and final presentation). • Attendance (20%): • Attendance is required. If ≥3 of the 11 classes are missed you will automatically not pass. • Final Presentation (10%): • Required: No final presentation, no pass BMTRY 789 Intro. To SAS Programming

  4. What are your expectations? BMTRY 789 Intro. To SAS Programming

  5. Syllabus (cont.) DETAILED STATEMENT OF OBJECTIVE: To introduce students to the concepts and methods of programming using SAS, and to expose them to other statistical software packages through guest lecturers. At the end of the course, the student will be able to: 1.      Read basic SAS syntax and functions; 2.      Enter raw data and import data from other sources into SAS; 3.      Manipulate SAS data to construct flat and vertical files structured to answer specific research questions; 4.      Program procedures to describe the characteristics of continuous and categorical variables; 5.      Be aware of other software packages and the conditions under which they may be superior to SAS for analytical purposes; 6.      Be able to debug programs and to use assorted references, both online and text, to learn new SAS procedures and functions, as well as solve programming challenges. 7.      Be familiar with individuals at MUSC with extensive experience in data manipulation, SAS and other programming languages. BMTRY 789 Intro. To SAS Programming

  6. CLASS SCHEDULE BMTRY 789 Intro. To SAS Programming

  7. CLASS SCHEDULE (cont.) BMTRY 789 Intro. To SAS Programming

  8. SAS Help Resources Nothing replaces experience / trial and error • Help files from the program, all the manuals you could ever want or need! • SAS Books by users (I have a shelf full) • SAS on the web: www.SAS.com BMTRY 789 Intro. To SAS Programming

  9. Example *Import Data using the File->Import Data pull down menu; *Call the new SAS data set STROKE; *Add a new hypertension indicator to the data set based on bp; *Print the new data set out to the screen; Libname Annie “C:\DATA”; DATA Annie.Stroke; Set Stroke; If sbp > 140 and dbp > 90 then Hypertensive=1; Else If sbp = . Or dbp = . Then Hypertensive=.; Else Hypertensive = 0; RUN; PROC PRINT DATA = Annie.Stroke; /*Prints the results*/ RUN; BMTRY 789 Intro. To SAS Programming

  10. Commenting Your Code Comments are usually used to annotate the program, making it easier for someone to read your program and understand what you have done and why. YOU WILL NOT GET FULL CREDIT IN THIS CLASS IF YOUR CODE ISN’T VERY WELL COMMENTED! BMTRY 789 Intro. To SAS Programming

  11. Rows/Columns & Data Types • What is the SAS lingo for Rows of Data? • What is the SAS lingo for Columns? • What are the two types of data? • Where do dates fit in? BMTRY 789 Intro. To SAS Programming

  12. Rules for SAS names • How long (# of characters) can variable names be? • What are the two things that can begin a variable name? • What can NOT be contained in a variable name? • Is SAS case sensitive? When? BMTRY 789 Intro. To SAS Programming

  13. Reading the SAS Log Every time you run a SAS job, READ the Log window first! Every time you have a question for me I will ask, “What does you SAS Log say?”. BMTRY 789 Intro. To SAS Programming

  14. Let’s go over how to use the SAS Import Wizard to get Excel Data into SAS… • Open the Import Wizard Instructions. BMTRY 789 Intro. To SAS Programming

  15. Test Your SAS Knowledge • Find the class 1 in-class assignment from the class website. http://people.musc.edu/~simpsona/SASclass/Class_Notes.html • Use the Excel Data file to complete the questions. • For brand new SAS programmers we will do this together. • New students to SAS, please do the Practice problems on the websites’ Homework page first. BMTRY 789 Intro. To SAS Programming

More Related