Click here to see the SAS code.
Click here to see the example.

---------------------------------------------------------------

This is a sas/graph imitation of the 'webalizer' graphs, such as...
http://robslink.com/webalizer/

This example shows that once you get the web log info into sas datasets, 
sas/graph can definitely create useful web-analytics plots (very similar 
to the webalizer ones).  And also, imho, the sas graphs are better, 
because the sas version has drilldowns on *both* the bars and the table,
whereas the webalizer version only had drilldowns in the table.
(The sas bars also have charttips/hover-text, in addition to the 
drilldowns.)

One other small change, I re-arranged the order of the columns in the
tables, so they correspond with the order the bars (colors) appear in
the plots.

And, I use the _exact_ same color in the bars & column headings,
so users can easily see which ones are related.

--------

Details:

I'm not generally a big fan of overlapping bars, but in cases like this
where the back-most bar is *always* guaranteed to be taller than the
front bars, I guess there's no harm (and it also allows you to have 
wider bars than if you'd put them side-by-side, bo maybe it's actually
a little easier to read.

It's a little challenging to do graphs like this in sas, because 
gchart does not allow you to overlap bars -- but, not to fret, 
annotate can be used to draw custom bars, just about any way 
you want them...

I use the gchart html= option to add charttips & drilldowns to 
the bar charts.

I use 'ods htmlpanel' to lay out the graphs side-by side.

I use 'proc report' to do the tables, and in order to get the 
table laid out as similarly as possible to the webalizer one, I
actually position 2 tables side-by-side (which unfortunately puts
the month in there twice).  If we opt to do our own table, not 
trying to duplicate the webalizer one ver-batim, then we could 
do a nicer-looking one.  I embed html in the month values in the
table to do the drilldowns.

Note that the drilldowns go to the actual webalizer drilldown pages
(we could similarly produce our own sas drilldowns, if we had 
access to the data).

Back to Samples Index