Sample 25618: Use the JAVA device driver to create a graph for the web with local drill down capability
This sample uses the JAVA device driver to create graph for the web with local drill down capability. After displaying the graph in a web browser, click on a bar to drill down on the graph.
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 the JAVA device driver to create graph for the web with local drill down capability. After displaying the graph in a web browser, click on a bar to drill down on the graph.
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 the data set SALES */
data sales;
length Region $ 4 State $ 2;
format Sales dollar8.;
input Region State Sales Year Qtr;
datalines;
West CA 13636 1999 1
West OR 18988 1999 1
West CA 14523 1999 2
West OR 18988 1999 2
East MA 18038 1999 1
East NC 13611 1999 1
East MA 11084 1999 2
East NC 19660 1999 2
West CA 12536 1998 1
West OR 17888 1998 1
West CA 15623 1998 2
West OR 17963 1998 2
East NC 17638 1998 1
East MA 12811 1998 1
East NC 12184 1998 2
East MA 12760 1998 2
;
run;
/* Close the listing destination */
ods listing close;
/* Specify a directory for the HTML output */
filename odsout 'c:\temp';
/* Open the HTML destination */
ods html path=odsout body='g25618.html'
codebase="http://www2.sas.com/codebase/graph/v92";
/* Create the graph using the JAVA device driver */
goptions reset=all device=java
xpixels=600 ypixels=400
cback=white border;
/* Add a title to the graph */
title1 font='Arial/bold' h=14pt
'Click on a bar to drill down on the graph';
/* Create the graph */
proc gchart data=sales;
vbar3d region / sumvar=sales group=year subgroup=state;
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 the JAVA device driver to create graph for the web with local drill down capability.
| Type: | Sample |
| Topic: | Third Party ==> Output ==> Device Drivers ==> Java SAS Reference ==> ODS (Output Delivery System) SAS Reference ==> Procedures ==> GCHART
|
| Date Modified: | 2006-05-11 03:02:58 |
| Date Created: | 2005-05-23 14:19:21 |
Operating System and Release Information
| SAS System | SAS/GRAPH | All | 9.1 TS1M0 | n/a |