Sample 51228: Use SAS/GRAPH® to write multiple graphs to a PowerPoint® document using the ODS Destination for PowerPoint
Beginning with SAS® 9.4, the new ODS Destination for PowerPoint creates native PowerPoint documents. The sample code on the
Full Code tab demonstrates how to use the GPLOT procedure to write multiple graphs to a single PowerPoint document. This sample code writes three graphs to the PowerPoint document.
These sample files and code examples are provided by SAS Institute
Inc. "as is" without warranty of any kind, either express or implied, including
but not limited to the implied warranties of merchantability and fitness for a
particular purpose. Recipients acknowledge and agree that SAS Institute shall
not be liable for any damages whatsoever arising out of their use of this material.
In addition, SAS Institute will provide no support for the materials contained herein.
You must run this sample code with SAS 9.4 since the ODS POWERPOINT statement is new beginning with this release.
data cars;
set sashelp.cars;
if cylinders=4 or cylinders=6 or cylinders=8;
run;
proc sort data=cars;
by cylinders;
run;
goptions reset=all device=png htext=14pt;
ods _all_ close;
ods powerpoint file='cars.pptx' image_dpi=300;
symbol1 interpol=none value=dot height=1.5 color=libg;
axis1 minor=none;
proc gplot data=cars;
plot mpg_city*horsepower / vaxis=axis1;
by cylinders;
run;
quit;
ods _all_ close;
ods listing;
These sample files and code examples are provided by SAS Institute
Inc. "as is" without warranty of any kind, either express or implied, including
but not limited to the implied warranties of merchantability and fitness for a
particular purpose. Recipients acknowledge and agree that SAS Institute shall
not be liable for any damages whatsoever arising out of their use of this material.
In addition, SAS Institute will provide no support for the materials contained herein.
This sample illustrates how to use SAS/GRAPH® to write multiple graphs to a PowerPoint® document using the ODS Destination for PowerPoint.
| Date Modified: | 2013-10-08 15:44:19 |
| Date Created: | 2013-10-02 13:24:17 |
Operating System and Release Information
| SAS System | N/A | z/OS | 9.4 TS1M0 | |
| Z64 | 9.4 TS1M0 | |
| Apple Mobile Operating System | 9.4 TS1M0 | |
| Microsoft® Windows® for 64-Bit Itanium-based Systems | 9.4 TS1M0 | |
| Microsoft® Windows® for x64 | 9.4 TS1M0 | |
| Microsoft Windows 8 Enterprise 32-bit | 9.4 TS1M0 | |
| Microsoft Windows 8 Enterprise x64 | 9.4 TS1M0 | |
| Microsoft Windows 8 Pro 32-bit | 9.4 TS1M0 | |
| Microsoft Windows 8 Pro x64 | 9.4 TS1M0 | |
| Microsoft Windows Server 2008 R2 | 9.4 TS1M0 | |
| Solaris for x64 | 9.4 TS1M0 | |
| Microsoft Windows Server 2008 for x64 | 9.4 TS1M0 | |
| Microsoft Windows Server 2012 Datacenter | 9.4 TS1M0 | |
| Microsoft Windows Server 2012 Std | 9.4 TS1M0 | |
| Windows 7 Enterprise x64 | 9.4 TS1M0 | |
| Windows 7 Professional x64 | 9.4 TS1M0 | |
| 64-bit Enabled AIX | 9.4 TS1M0 | |
| 64-bit Enabled HP-UX | 9.4 TS1M0 | |
| 64-bit Enabled Solaris | 9.4 TS1M0 | |
| HP-UX IPF | 9.4 TS1M0 | |
| Linux | 9.4 TS1M0 | |
| Linux for x64 | 9.4 TS1M0 | |