Create Multi-Sheet Excel Workbooks Using SAS

Create Multi-Sheet Excel Workbooks Using SAS
Slide Note
Embed
Share

Output Delivery System (ODS) in SAS allows you to specify where the SAS output goes by using ExcelXPTagset, a part of ODS MARKUP. This tool translates SAS output into an XML file that can be opened with Excel. Explore the power of ODS statements, syntax, style templates, and formatting options in SAS to enhance your data presentation techniques.

  • SAS Programming
  • Excel Workbooks
  • ODS System
  • Data Visualization

Uploaded on Mar 20, 2025 | 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.If you encounter any issues during the download, it is possible that the publisher has removed the file from their server.

You are allowed to download the files provided on this website for personal or commercial use, subject to the condition that they are used lawfully. All files are the property of their respective owners.

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.

E N D

Presentation Transcript


  1. Using SAS to Create Multi-Sheet Excel Workbooks TAIR 2017 Amber Lummus College of the Mainland

  2. Moving from SPSS to SAS SAS Programming Courses COM s Program Review The power of Google and SAS Instructors SAS Background

  3. ODS (Output Delivery System) allows you to indicate where SAS output goes There are several ODS options ExcelXPTagset is part of ODS MARKUP The markup language translates the SAS output to an XML file that can be opened with Excel Requirements SAS 9.1 or later Excel 2002 or later What is the ExcelXP Tagset?

  4. SAS code is wrapped in ODS statements The opening statement specifies which ODS output destination you are using (ExcelXP Tagset) and the location for the XML file The closing statement closes the ODS output destination, in this case, the XML file Following the closing statement, specify where you want the next output to go (typically ODS listing) Basic Syntax

  5. Basic ODS Syntax

  6. Default Style for XML Output

  7. There are many style templates that change the overall appearance of the output Options can also be added to the opening ODS statement Overall appearance Printing Style Templates

  8. Style Template and Tagset Options

  9. XML Output with a Style Template

  10. Some of the standard SAS formatting options don t work in the XML output files TAGATTR Style Attributes Specify type Specify Excel format Assign Excel formulas (R1C1 style) Style Details

  11. SAS Code with Standard SAS Formats

  12. SAS Results Window Output

  13. XML File Output with Standard SAS Formats

  14. SAS Code with TAGATTR Style Attributes

  15. XML File Output with TAGATTR Style Attributes

  16. Control which output is on which Excel sheet within the workbook Sheet names Change options for individual sheets Sheet Options

  17. SAS Code with Sheet Specific Options

  18. XML File Output with Sheet Specific Options

  19. Macros Create multiple workbooks, each with multiple sheets Convert the XML output to XLSX Download convert macro from SAS support site Add code to invoke the macro Additional Enhancements

  20. SAS Macro to Convert XML files to XLSX files

  21. ODS Excel XP Tip Sheet https://support.sas.com/rnd/base/ods/odsmarkup/TipSheet_ods_xl_xp.pdf Base SAS Demo: The ExcelXP Tagset and Microsoft Excel https://support.sas.com/rnd/base/ods/odsmarkup/excelxp_demo.html#forma ts Understanding the ExcelXP Tagset Lecture Transcript https://support.sas.com/training/tutorial/el/libsppg1_et.pdf References and Resources Convert files created using an ODS destination to native Microsoft Excel files http://support.sas.com/kb/43/496.html Create or Delete a Custom Number Format (Excel) https://support.office.com/en-us/article/Create-or-delete-a-custom-number- format-78f2a361-936b-4c03-8772-09fab54be7f4 Creating Stylish Multi-Sheet Excel Workbooks the Easy Way with SAS http://support.sas.com/resources/papers/proceedings11/170-2011.pdf Don t Gamble with Your Output: How to Use Microsoft Formats with ODS https://support.sas.com/resources/papers/proceedings11/266-2011.pdf

More Related Content