A tool for generating HTML visualizations of code metrics. As a proof of concept, the first visualization is to create treemaps of CSV data like in this example:
See also the description in Josra
Try the simple demo:
$ ./demo.sh
or
> demo.bat
The demo
scripts run the tool with doc/input-example.csv as
input and produces output in output.html
.
Open output.html in a browser to see the generated treemap. Click the squares to drill down. You navigate back to parent level using right mouse click.
The tool is built and run using Gradle. You do not need to install Gradle, because the Gradle wrapper is used.
The example commands in this section use shell scripts, but there are Windows batch
equivalents (with .bat
extension).
Java 1.8 is required, but currently you can compile with 1.7 (defined in build.gradle
)
$ ./gradlew installDist
Produces an executable in build/install/metricviz
.
$ cd build/install/metricviz/bin/
$ ./metricviz --input=<input-file.csv> --output=<output-file.html>
$ ./gradlew javadoc
$ cd build/docs/javadoc/
The proof of concept supports a CSV input file as described in doc/input-format.md. The tool may later be extended to support other structured formats like JSON or XML. The support may be driven by the choice of code analysis tools used to generate data.
The tool writes an HTML file that uses Google Treemaps to create a drill-down treemap visualization of the input.