[ Top | Up | Prev | Next | Map | Index ]

Analog 6.0: Hierarchical reports

Some of the non-time reports have a hierarchical (or tree) structure: so, for example, each domain in the Domain Report can have subdomains listed under it, which in turn can have sub-subdomains, and so on. This section describes commands for managing hierarchical reports.

First, you need to be able to control what gets listed in the reports. For this you need to use the SUB family of commands. So, for example, the command SUBDIR /~sret1/* would ensure that the Directory Report would not only contain an entry for the sum of my files, but also one for each of my subdirectories, something like this:

29,111: /~sret1/
10,234:   /~sret1/analog/
 5,179:   /~sret1/backgammon/
11,908: /~steve/
You can have more than one * in the command. For example
would list the whole Domain Report two levels deep.

If you specify a SUB command, all the intermediate levels are included automatically. So, for example, after

SUBDOMAIN statslab.cam.ac.uk
cam.ac.uk and ac.uk will be included in the Domain Report too, and after *.*.ac.uk, *.ac.uk will be included.

Here are examples of the other four SUB commands:

SUBTYPE *.gz         # in the File Type Report
SUBBROW */*          # e.g. Netscape/4 in the Browser Summary
SUBBROW Netscape/*.*  # add minor version numbers for Netscape
REFDIR http://search.yahoo.com/*   # Referring Site Report
SUBORG *.aol.com     # Organisation Report
SUBORG *.*.com       # Break down all .com's

The SUBDOMAIN command (but none of the others) can include a second argument describing the subdomain. For example

SUBDOMAIN cam.ac.uk 'University of Cambridge'
Then that subdomain will be listed with its translation in the Domain Report. You can also have numerical subdomains: e.g.,
SUBDOMAIN 131.111 'University of Cambridge'
If you sort the subdomains alphabetically, the numerical ones will also be sorted alphabetically, not numerically. I don't think this will cause any problems.

One other use for the SUBDIR command is if you have used the second argument to the LOGFILE command. Suppose you have translated files like /index.html into http://www.mycompany.com/index.html. Then the command

SUBDIR http://*    # or
SUBDIR http://*/*
would be appropriate to make the Directory Report look right.
The lower levels of each report have FLOOR and SORTBY commands which work exactly the same as those we have already seen for the top level. These commands are SUBDIRFLOOR, SUBDOMFLOOR, SUBORGFLOOR, SUBTYPEFLOOR, SUBBROWFLOOR and REFDIRFLOOR; and SUBDIRSORTBY, SUBDOMSORTBY, SUBORGSORTBY, SUBTYPESORTBY, SUBBROWSORTBY and REFDIRSORTBY.

A sub-item is listed in a hierarchical report only if it is above the sub-FLOOR, and it is included with a SUB command, and it is not excluded because of an INCLUDE or EXCLUDE command, and its immediate parent is listed. For example, specifying

SUBDIR /*/*/
would list the three subdirectories with most requests under each directory. SUBDIRFLOOR 1:r would have listed any subdirectory with at least 1% of the maximum number of requests of any top level directory.

The three file reports (Request Report, Redirection Report and Failure Report) and the three referrer reports (Referrer Report, Redirected Referrer Report and Failed Referrer Report) are not fully hierarchical, but they do list search arguments together under the file to which they refer (provided that the arguments have been read in: see the ARGSINCLUDE command). So they have similar sub-FLOOR and sub-SORTBY commands, namely REQARGSFLOOR, REDIRARGSFLOOR, FAILARGSFLOOR, REFARGSFLOOR, REDIRREFARGSFLOOR and FAILREFARGSFLOOR; and REQARGSSORTBY, REDIRARGSSORTBY, FAILARGSSORTBY, REFARGSSORTBY, REDIRREFARGSSORTBY and FAILREFARGSSORTBY. The same applies to the Operating System Report with its subdivisions of operating systems: it has SUBOSFLOOR and SUBOSSORTBY.

The lower levels of a hierarchical report temporarily interrupt the top level, and even though they are indented, this can sometimes make it look as if the report is out of order. If you have a lot of sub-items, for example in the Referrer Report if there are a lot of search arguments, then including the N column can help to make it clearer again.
Sometimes one item in the pie chart takes up most of the pie. In this case, you can elect to plot its sub-items on the chart instead, by using the *CHARTEXPAND family of commands. For example
will use Windows 98, Windows NT etc. as wedges in the pie chart, instead of accumulating all the Windows versions together in one wedge. The complete list of these commands is DIRCHARTEXPAND, DOMCHARTEXPAND, ORGCHARTEXPAND, TYPECHARTEXPAND, BROWCHARTEXPAND, OSCHARTEXPAND, REQCHARTEXPAND, REDIRCHARTEXPAND, FAILCHARTEXPAND, REFCHARTEXPAND, REDIRREFCHARTEXPAND, FAILREFCHARTEXPAND and REFSITECHARTEXPAND. The CHARTEXPAND commands can take a comma-separated list (without spaces) as an argument, but not wildcards.

Just as for top-level items, sub-items will only be included if they are listed in the main table for the report. And so if an item does not have any sub-items listed, it will not be expanded, even if you asked for it to be. This means that you may need to use the appropriate SUB commands or SUBFLOOR commands to make sure that the sub-items do get listed. For example


Also, sub-items will only appear on the pie chart if they are large enough to get on in their own right. Note that if an item has any sub-items listed, and is expanded, then the item itself will no longer appear on the chart, only any sub-items which are large enough.

Go to the analog home page.

Stephen Turner
19 December 2004

Need help with analog? Use the analog-help mailing list.

[ Top | Up | Prev | Next | Map | Index ]