Presentation is loading. Please wait.

Presentation is loading. Please wait.

SAS Software Version 8 The Output Delivery System.

Similar presentations


Presentation on theme: "SAS Software Version 8 The Output Delivery System."— Presentation transcript:

1 SAS Software Version 8 The Output Delivery System

2 What is ODS? SAS Software Version 6 produced traditional monospace output Other current software is WYSIWYG with control over fonts, colours etc Version 8 has ODS to cover the difference, and more… SAS Software Version 6 produced traditional monospace output Other current software is WYSIWYG with control over fonts, colours etc Version 8 has ODS to cover the difference, and more…

3 How Does ODS Work Data Component Table Definition Output Object SAS DataSet Listing Output HTML Output Printer Output ODS Output: ?? Future Expansion

4 ODS Sources Sources of ODS include: SAS Procedures (including SAS/GRAPH)SAS Procedures (including SAS/GRAPH) The Data Step (The Data Step (ODS option in the FILE statement) Sources of ODS include: SAS Procedures (including SAS/GRAPH)SAS Procedures (including SAS/GRAPH) The Data Step (The Data Step (ODS option in the FILE statement)

5 Sample ODS... ODS LISTING CLOSE; ODS HTML BODY=‘OUTPUT1.HTM’; PROC PRINT …; RUN; ODS HTML CLOSE; ODS LISTING;...... ODS LISTING CLOSE; ODS HTML BODY=‘OUTPUT1.HTM’; PROC PRINT …; RUN; ODS HTML CLOSE; ODS LISTING;... Stop writing to the Output Window Write to the specified HTML File Stop writing to the HTML File Write to the Output Window again

6 ODS Example 1

7 ods html body='Test1.htm'; proc print data=work.Launchers noobs label; title 'SPLATT Launch Vehicles'; run; proc print data=work.Voyages heading=h noobs label; id Voyage_ID; by notsorted Launcher; pageby Launcher; title 'SPLATT Voyages'; run; ods html close; NOTE: Entire sample code is located on the Notes page for this slide..

8 ODS Example 2

9 ods html file='Test2-body.htm' contents='Test2-contents.htm' frame='Test2-frame.htm' body='Test2-page.htm'; proc tabulate data=work.Voyages; title 'SPLATT Voyages Summary'; class Launcher Mission_Success; var Mission_Cost; table Launcher, Mission_Success*N=' '*f=8.0 Mission_Cost*(SUM MEAN)*f=dollar13.0; run; pattern1 c=red v=solid; pattern2 c=green v=solid; proc gchart data=work.Voyages; title 'SPLATT Voyages Summary'; vbar Mission_Success / group=Launcher subgroup=Mission_Success nolegend; run; quit; ods html close;

10 PROC TEMPLATE Features PROC TEMPLATE creates and modifies these definitions, which ODS uses to create formatted output. STYLE: Customize the presentation of all output. TABLE: Customize a single output object. PROC TEMPLATE creates and modifies these definitions, which ODS uses to create formatted output. STYLE: Customize the presentation of all output. TABLE: Customize a single output object.

11 PROC TEMPLATE Example 1

12 ods path sasuser.templat(update) sashelp.tmplmst(read); proc template; define style customdefault; parent=styles.default; replace color_list / 'fgB2' = cx0066AA 'fgB1' = cx004488 'fgA4' = cxFFFFFF 'bgA4' = cx880000 'bgA3' = cxBBBB00 'fgA2' = cx000000 'bgA2' = cx999900 'fgA1' = cx000000 'bgA1' = cxF0F0F0 'fgA' = cx002288 'bgA' = cx640064; replace titlesandfooters / foreground=cxFFFFFF font=fonts("titlefont2") font_size=6; style header from header / font_style=italic; style table from table / rules=cols cellspacing=0 borderwidth=2; end; run; ods html body='Tabulate2.htm' style=customdefault; proc tabulate data=work.Voyages; title 'SPLATT Voyages Summary'; class Launcher Mission_Success; var Mission_Cost; table Launcher,Mission_Success*N=' '*f=8.0 Mission_Cost*(SUM MEAN)*f=dollar13.0; run; ods html close;

13 PROC TEMPLATE Example 2

14 ods html body='Tabulate3.htm' style=customdefault; proc format; value meantl low-100000000='Green' 100000000<-150000000='Yellow' 150000000<-high='Red'; run; proc tabulate data=work.Voyages; title 'SPLATT Voyages Summary'; class Launcher Mission_Success; var Mission_Cost; table Launcher,Mission_Success*N=' '*f=8.0 Mission_Cost*(SUM MEAN*[s=[foreground=meantl.]])*f=dollar13.0; run; ods html close;

15 ConclusionConclusion ODS provides an easy way to create HTML pages Easy Traffic Lighting Futures may include XML and PDF Files Try it!!! ODS provides an easy way to create HTML pages Easy Traffic Lighting Futures may include XML and PDF Files Try it!!!

16 QuestionsQuestions References: SAS Online Doc® Version Eight The Complete Guide to the SAS Output Delivery Systemmichael_matthews@qual-it.com.auhttp://www.qual-it.com.auReferences: SAS Online Doc® Version Eight The Complete Guide to the SAS Output Delivery Systemmichael_matthews@qual-it.com.auhttp://www.qual-it.com.au


Download ppt "SAS Software Version 8 The Output Delivery System."

Similar presentations


Ads by Google