Sample 25507: Use PROC GBARLINE with the ACTIVEX driver to create a bar/line graph using an ODS style
This sample uses PROC GBARLINE with the ACTIVEX driver to create a bar/line graph which uses the EDUCATION style.
To view the graph that the ACTIVEX driver creates, you must use Microsoft Internet Explorer
as your web browser and you must have the SAS® 9.2 ActiveX graph control locally installed on your Windows machine.
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 uses PROC GBARLINE with the ACTIVEX driver to create a bar/line graph which uses the EDUCATION style.
To view the graph that the ACTIVEX driver creates, you must use Microsoft Internet Explorer
as your web browser and you must have the SAS® 9.2 ActiveX graph control locally installed on your Windows machine.
The graphics output in the Results tab was produced using SAS® 9.2. Submitting
the sample code with releases of SAS prior to SAS 9.2 might produce different results.
/* Create a sample data set */
data nyse;
informat Day date9.;
format Day date5.;
input Day $ High Low Close Volume;
volume=volume/1000;
datalines;
02AUG2002 10478.76 10346.24 10426.91 1908809
03AUG2002 11042.92 10298.44 10274.65 1807543
04AUG2002 10498.22 10400.31 10456.43 1500656
05AUG2002 10694.47 10636.32 10762.98 1498403
06AUG2002 10801.12 10695.13 10759.48 1695602
;
run;
/* Close the Listing destination */
ods listing close;
/* Specify a directory for the HTML output */
filename odsout 'c:\temp';
/* Open the HTML destination using */
/* STYLE=EDUCATION */
ods html path=odsout body='g25507.html'
style=education;
/* Create the graph using the ACTIVEX device driver */
goptions reset=all device=activex
xpixels=600 ypixels=400 border;
/* Add a title to the graph */
title1 font='Arial/bold' h=14pt
"NYSE Closing Price and Volume By Day";
proc gbarline data=nyse;
bar day / sumvar=volume discrete;
plot /sumvar=close;
run;
quit;
/* Close the HTML destination and open the */
/* Listing destination. */
ods html 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 uses PROC GBARLINE with the ACTIVEX driver to create a bar/line graph which uses the EDUCATION style.
Type: | Sample |
Topic: | SAS Reference ==> Procedures ==> GBARLINE Query and Reporting ==> Creating Reports ==> Graphical ==> Graph Types ==> Charts ==> Special Charts
|
Date Modified: | 2005-07-23 03:02:37 |
Date Created: | 2005-05-23 14:12:04 |
Operating System and Release Information
SAS System | SAS/GRAPH | All | 9.1 TS1M0 | n/a |