Click here to see the SAS code. Click here to see the example. --------------------------------------------------------------- Note: You will need to disable google toolbar popup blocking (ie, enable popups) for the charttips/drilldowns in this example to work. The following google doc seems to indicate you can click the 'popup button' to add this site to the 'white list', but that doesn't seem to work in the version of IE/google-toolbar I'm using. In mine, the note at the bottom of the window says to "Ctrl+bar" to allow the popup -- that seems to work. ----- ** Note: for tooltips/drilldown to work in dev=javameta, you *must* specify the imagemap= option. It doesn't matter what dataset you specify as the imagemap output (you can use imagemap=foo) because you won't use it for anything ... but by specifying this option, it causes the metacodes to be generated in the metacode output. The drilldown in this example is done in the traditional SAS/Graph way, but using the new "goptions device=javameta" rather than gif ... First, a character variable is created, containing the html tags for the drilldown (href=) and the text charttip/rollover-text (title=) as follows ... length htmlvar $500; htmlvar='title='||quote( 'State: '|| trim(left(st)) ||'0D'x|| 'Population: '|| trim(left(put(population,comma12.0))) ) ||' '|| 'href="http://www.state.'||trim(left(lowcase(st)))||'.us"'; Then that variable is specified using the "html=" option in the SAS/Graph "proc gplot" as follows... proc gchart data=mydata; hbar st / discrete type=sum sumvar=population ascending nostats maxis=axis1 raxis=axis2 autoref cref=gray clipref coutline=black cframe=white html=htmlvar <-------- here! des="" name="&name" ; run; The output is created using ODS HTML, and "goptions device=javameta". With javameta, only *one* output file is produced - a single html file containing the basic java "metacodes" to re-draw the graph on the client end (ie, the web browser). If you look at the html file, you can see the metacodes, but you won't really be able to identify which metacodes represent your data (like you could with the dev=java and dev=activex). The advantage to dev=javameta is that it even works with very old versions of java, and you can zoom & pan the graph without losing resolution in the text & graphics (not such a big advantage in a simple bar chart like the one in this example, but *very* useful when you're viewing a very crowded graph or map!). Back to Samples Index