MASUG September 15, 2005. Agenda  Guest Introductions  John Boling – SAS inSchool  Tim Garton – Health Forecasts  Announcements  Tips & Tricks 

Slides:



Advertisements
Similar presentations
Summary Statistics/Simple Graphs in SAS/EXCEL/JMP.
Advertisements

Zhongmin Li and Geeta Mahendra
Introduction to Formatting VistaPHw Charts Brought to you by: The Vista Partnership February 2007.
No More Downloading - Using SAS/ODS to Create SAS Graphs and HTML Documents for z/OS Systems – Updated for SAS V9 June 25, 2009.
The INFILE Statement Reading files into SAS from an outside source: A Very Useful Tool!
Statistical Methods Lynne Stokes Department of Statistical Science Lecture 7: Introduction to SAS Programming Language.
Using ODS Regions to Create Custom Reports Kate Morrow, M.S. Statistician Vermont Oxford Network, Burlington, VT.
Introduction to Microsoft Excel 2010 Chapter Extension 3.
SAS ® graphics in motion Hi! I‘m Barbara… … and I‘m Kristan In the next 5 minutes we will guide you through our video poster „SAS ® graphics in motion“
Outline Proc Report Tricks Kelley Weston. Outline Examples 1.Text that spans columnsText that spans columns 2.Patient-level detail in the titlesPatient-level.
Controlling SAS Graphics using ANNOTATE Datasets Elizabeth Campagna University of Colorado Denver Colorado Health Outcomes Program Colorado Day – Denver.
MASUG December 5, Agenda Announcements Announcements Tips & Tricks Tips & Tricks Presentation: Presentation: Working Smarter, Not Harder with DDE:
Plots, Correlations, and Regression Getting a feel for the data using plots, then analyzing the data with correlations and linear regression.
Runcharts 101 Geoff Schierbeck Quality Leader Surgery BCPSQC.
Basic And Advanced SAS Programming
EXCEL PART 2. Chart Elements Chart Title Plot Area Data Marker X AxesCategory Name Y axes.
Let SAS Do the Coding for You! Robert Williams Business Info Analyst Sr. WellPoint Inc.
How to Build Tabular Dashboards Using Proc Report
The gchart Procedure The gchart Procedure is used to create bar charts of various types (it can also create pie charts. It’s most basic form would look.
Welcome to SAS…Session..!. What is SAS..! A Complete programming language with report formatting with statistical and mathematical capabilities.
FORMAT FESTIVAL AN INTRODUCTION TO SAS® FORMATS AND INFORMATS By David Maddox.
Instructor: Professor Cora Martinez, PhD Department of Civil and Environmental Engineering Florida International University.
AE4131 ABAQUS Lecture Part IV
Introduction to SAS/Graph Don Miller 812 Oswald Tower
SAS® Maps as Tools to Display and Clarify Healthcare Outcomes Barbara B. Okerson, HMC, Richmond, VA.
Introduction to SAS Essentials Mastering SAS for Data Analytics Alan Elliott and Wayne Woodward SAS ESSENTIALS -- Elliott & Woodward1.
UNLOCKING THE SECRETS HIDDEN IN YOUR DATA Data Analysis.
Tips & Tricks MASUG02/18/2005. Multiple Graphs on One Page.
Introduction to Excel Line Graphing The ‘Quick’ and ‘Easy’ guide to using Microsoft Excel for Line Graphing * Created by: Bunch of BHS science teachers.
1 Back Up with Each Submit One approach for keeping a dynamic back up copy of your current work.
Macro Overview Mihaela Simion. Macro Facility Overview Definition : The SAS Macro Facility is a tool within base SAS software that contains the essential.
Key Words: Functional Skills. Key Words: Spreadsheets.
Introduction to SAS/Graph 9.2 Ken Barz Colorado Prevention Center 22Oct2009 Ken Barz Colorado Prevention Center.
Advanced Stata Workshop FHSS Research Support Center.
HS115 Unit 7 Seminar December 22, 2010 David Rudnick, Instructor.
1 Data Manipulation (with SQL) HRP223 – 2010 October 13, 2010 Copyright © Leland Stanford Junior University. All rights reserved. Warning: This.
Creating a poster is easier than you think.
Copyright © 2014, SAS Institute Inc. All rights reserved. ACCESSIBILITY TIPS AND TRICKS FOR SAS PROGRAMMERS ED SUMMERS SENIOR MANAGER, ACCESSIBILITY.
Warm Up 1.What does the data to the right tell you? 2.Are there any trends that you notice about plant height?
Statistical Graphics for the SAS System Computing for Research I 01/29/2014 Nathaniel L Baker.
Creating and Using Custom Formats for Data Manipulation and Summarization Presented by John Schmitz, Ph.D. Schmitz Analytic Solutions, LLC Certified Advanced.
Effective SAS greplay’ing and how to avoid stretching By David Mottershead Senior Programmer, Quanticate.
1. 2 Word Processing Word Processing is writing words and sentences on the computer. It is easy to change or move text in a word document. People use.
PROC GPLOT GPLOT is used to make two dimensional scatter-plots. General Syntax: proc gplot data=data-set options; plot y-variable*x-variable/options; run;
YET ANOTHER TIPS, TRICKS, TRAPS, TECHNIQUES PRESENTATION: A Random Selection of What I Learned From 15+ Years of SAS Programming John Pirnat Kaiser Permanente.
Creating Geographic Rating Area Maps: How to Combine Counties, Split Counties, & use Zip Code Boundaries Rick Andrews Office of the Actuary Centers for.
SAS ® is a very powerful tool when producing Graphics. A single graphical data step can easily create a Kaplan Meier Plot, but there is no single graphical.
SAS/GRAPH The Basics. Today’s Topics GOPTIONS GPLOT GCHART GCONTOUR G3D.
1 By Shafi Chowdhury PhUSE 2011 Managing Data Issues.
1 Data Manipulation (with SQL) HRP223 – 2009 October 12, 2009 Copyright © Leland Stanford Junior University. All rights reserved. Warning: This.
CMS SAS Users Group Conference Learn more about THE POWER TO KNOW ® October 17, 2011 PROC GMAP, HTML and You Thomas Kornfield, CMS.
Submitted By: DRPU Software Team Site:
Charts MOAC Lesson 6.
CMS SAS Users Group Conference Learn more about THE POWER TO KNOW ® October 17, 2011 Using SAS® to Create Custom Healthcare Graphics Barbara B. Okerson.
Behind the Scenes with SAS®: Using Customer Graphics in SAS® Output Louise Hadden Abt Associates Inc.
SAS ® 101 Based on Learning SAS by Example: A Programmer’s Guide Chapters 14 & 19 By Tasha Chapman, Oregon Health Authority.
03/20161 EPI 5344: Survival Analysis in Epidemiology Estimating S(t) from Cox models March 29, 2016 Dr. N. Birkett, School of Epidemiology, Public Health.
SAS ® 101 Based on Learning SAS by Example: A Programmer’s Guide Chapters 5 & 6 By Ravi Mandal.
A few tricks to take you beyond the basics of Microsoft Office 2010
Project title Scheduled dates Team members JAN FEB MAR APR MAY JUN
Computing for Research I 01/26/2011 N. Baker
Let’s Talk About Variable Attributes
Author: Kaiqing Fan Company: Mastech Digital Inc.
Work out angle
SAS/Graph to help data Dose/Concentration consistency review
Presentation transcript:

MASUG September 15, 2005

Agenda  Guest Introductions  John Boling – SAS inSchool  Tim Garton – Health Forecasts  Announcements  Tips & Tricks  Member Presentation  SAS inSchool

Announcements  and now a few words from Gordon Galey……..

Annotating Graphs Is Simpler Than You Think (With An Excursion) Walt Smith FedEx Forecasting MASUG Sep 15, 2005

Graphs can be powerful ways to draw a picture of your data. Key information can be “drawn” on the graph to make the graph tell even more of the story. A simple example:

Do you see anything obvious?

There seems to be “events” in this time series – specifically a significant shift up between Dec03 and Jun04 – and another shift down about Jul05 Assuming the cause is known (in this case, a large account was won and lost), this information can be added.

This is more clear:

Why should I do this with SAS? I could just import my data into Excel and build a graph in just a few clicks (well, OK, more than a few clicks). What if you need to do it every month? Every week? Every day? For dozens – hundreds of graphs? – Still want to use Excel?

First the code to produce the basic graph proc gplot data=mydata.random_ts; plot sales * date / frame plot sales * date / frame haxis = axis1 vaxis = axis2 haxis = axis1 vaxis = axis2 cframe = cxeeeedd ; cframe = cxeeeedd ; format sales comma5.0; format sales comma5.0; format date monyy5.; format date monyy5.;run;

Then the options, symbol, and axis statements that will help dress it up. options orientation = landscape; goptions reset = all device = gif gunit = pct ftitle = swissb htitle = 5 ftext = swiss htext = 3 cback = cxbbc4cf ; symbol1 color=black interpol=join value=dot height=2 width=3 line=1; %let haxis = '01jun2002'd '01dec2002'd '01jun2003'd '01dec2003'd; %let haxis = &haxis '01jun2004'd '01dec2004'd '01jun2005'd '01dec2005'd; %let haxis = &haxis '01jun2006'd; axis1 label=none minor=none order=( &haxis ); axis2 label=none minor=none; title1 "Sales Region: Random";

Now for the annotations – SAS/Graph procedures accept an “annotate” dataset that contains the annotate information. Annotate information can be very simple or very complex according to your needs. An annotate dataset is simply a dataset that has certain “annotate” variables in it. The basic variables are the x,y coordinates to place the text (or object), the size, color, etc, and the function to perform (label, draw, etc)

The annotate data step code data anno; length color function style $8; length text $200; length x y 8; xsys = '2'; ysys = '2'; hsys = '5'; function = 'label'; set mydata.random_ts; if ( date = &event1 ) then do; x = date; y = sales + 150; size = 4; text = 'ABC Account'; style = 'swiss'; color = 'blue'; position = 'A'; output; y = sales + 75; size = 2; text = 'D'; style = 'marker'; position = 'B'; output; end; if ( date = &event2 ) then do; x = date; y = sales - 150; size = 4; text = 'Lost Account'; style = 'swiss'; color = 'red'; position = 'E'; output; y = sales - 75; size = 2; text = 'C'; style = 'marker'; position = 'E'; output; end; run;

Variables xsys, ysys, hsys specify the “coordinate system” for x, y values and sizes of things (like text)

Simplified code using 3 annotate macros data anno; %avars %xyhsys(2,2,5) set mydata.random_ts; if ( date = &event1 ) then do; %alabel(date, sales+150,'ABC Account',blue,,,4,swiss,A) %alabel(date, sales+75,'D',,,,2,marker,B) end; if ( date = &event2 ) then do; %alabel(date, sales-150,'Lost Account',red,,,4,swiss,E) %alabel(date, sales-75,'C',,,,2,marker,E) end; run;

The Annotate Dataset Has 4 Obs f p f p u o u o n s n s c c s s i c c s s i o t t t x y h d a s t o t t t x y h d a s t O l i y e s s s a l i i b o o l x y y y t e z o s r n e t x y s s s e s e n 1 blue label swiss ABC Account APR A 2 blue label marker D APR B 3 red label swiss Lost Account AUG E 4 red label marker C AUG E

Applying the annotate dataset is the easy part proc gplot data=mydata.random_ts; plot sales * date / frame haxis = axis1 vaxis = axis2 annotate = anno cframe = cxeeeedd ; format sales comma5.0; format date monyy5.; run;

Last, we want to send this graph in an – using SAS %let mygraph = mygraph.gif; filename gsfile "&mygraph"; goptions gsfname=gsfile gaccess=sasgastd; proc gplot data=mydata.random_ts; … run; filename dummy ; data _null_; file dummy to = subject = "Sales Region Report" attach = "&mygraph“ ; put 'Attached is the Sales Region Report.'; put 'If you have any questions feel free to call.'; run; SAS V9 Only

Member Presentation  Robert Hall, Baptist Memorial Health Care Corp.

SAS inSchool  John Boling, Director SAS inSchool