Child pages
  • 5.1.5 Studying Directory Structures (Hierarchical Data)

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Many data sets represent a hierarchy of categories. Think of the directories on your computer, many of which consist of sub-directories and files. Sci2 allows for the visualization of this hierarchical data in the form of trees. Using Sci2 you can scan any directory on  your computer or any network drive you have mapped to your machine. For example, run 'File > Read Directory Hierarchy' and select the Sci2 directory from where you have it installed on your machine and input the following parameters:

Image RemovedImage Added

You have several options when creating your directory tree. You can specify exactly how many levels to recurse, this is good if you know how many levels of the hierarchy you want to visualize. However, you You may not know how many levels there are in the directory structure you are scanning, in this case you can select to recurse the entire tree. However, you should be careful as this can be time consuming for large directory structures. Finally, you can choose to ignore files in the directory structure, focusing simply on the directories themselves.The result of scanning the Sci2 directory will be a Directory Tree in the data manager:

Image RemovedImage Added

This file is formatted in TreeML (.xml) a fairly easy to implement schema written in XML. TreeML files consist of a list of declarations and a series of branches ending in leaves. Below is a sample of the Sci2 Directory Structure TreeML file. The <branch> tag indicates a node that has children in the hierarchy, whereas the <leaf> tag indicates a node that has no children, so a node at the lowest level of the hierarchy:

...

To see the whole TreeML file righ-click on the "Directory Tree - Prefuse (Beta) Graph" file in the data manager and save the file as a TreeML (Prefuse) file:

Image RemovedImage Added

This will save a .xml file to the location you selected. You can open and edit XML files with a variety of programs such as Adobe Dreamweaver or Oxygen XML Editor, but any text editor will suffice. To visualize the tree structure select "Director Directory Tree - Prefuse (Beta)" and  run 'Visualization > Networks > Tree View (prefuse beta)':

Image RemovedImage Added

The resulting visualization will open in Prefuse:

Image RemovedImage Added

The initial visualization displays the first three levels of the directory structure. If you want to explore deeper in the directory structure, click on any directory in that level to see the directories nested below the level you have selected:

Image RemovedImage Added

If you are searching for a particular directory in a large hierarchy there is a search bar in the lower left-hand side of the Prefuse screen that allows users to find exact matches for search terms entered:

Image RemovedImage AddedImage Removed

Image Added

In addition to viewing hierarchical data structures in the Tree view, you can visualize them as Tree Maps by selecting the "Director Directory Tree - Prefuse (Beta)" and running 'Visualization > Networks > Tree Map (prefuse beta)':

Image RemovedImage Added

To learn more about tree maps see the documentation on our implementation of this algorithm click here. Finally, you can visualize the Sci2 directory structure as a graph you can do so by running 'Visualization > Networks > Radial Tree/Graph (prefuse alpha)' and the result will look similar to this:

Image RemovedImage Added

By selecting a node in the graph, each of its children in the hierarchy will be displayed in a darker red color. Anytime a node is selected the graph will rearrange to show the nodes directly beneath that node in the hierarchy. However, the radial tree view can be difficult to read for large directory structures.

...