How to use overview graph

  • Post author:
  • Post last modified:2021-01-01
  • Post category:How to use
  • Reading time:2 mins read

Sider Labs can analyze your code clones in various ways. In this article, we will explain how to use the code clone visualization feature in the “Overview” tab.

The Overview tab has a clone visualization panel. The wheel view extracts only the files that have code clones out of all the files in the project and illustrates the relationship between the files that have the clone code. The files in your project are displayed along a circular ring. The arcs that connect the ring fragments show the clones that exist between the two files. The width of the arc corresponds to the number of statements in the clone code, and you can click on the arc to view the actual code of the clone. On the other hand, clones inside the same file are represented as “bumps” on the circle. If you see an arc that is somewhat large and spans between two different files, we recommend you to check the details of the clone. You may be able to increase the code quality by grouping them together as utility functions or classes.

Example of wheel view

For example, the figure above shows an analysis of the repository of a 3D image processing software. There are more than 10 clone pairs with the number of statements ranging from 30 to 150 between “vmBlockVolume.cpp” (yellow) and “vmBlockVolume.cpp” (pink) (red dotted line in the lower right of the figure).

In the case of very large projects, the file names and arcs in the wheel chart are sometimes almost invisible. We keep trying to improve the UI/UX in the future, but if you mouse over a ring fragment in the wheel chart, complete file names will be shown. You can also zoom in by clicking the “Zoom In” button on the top right of the diagram. It is also possible to draw the top 10 most important files only or the top 10 largest scattered clones. Happy refactoring! Translated with (free version)

Aki Asahara

CEO of Sider. Aki joined Fixstars in 2008 and served major clients such as the US Airforce, MIT, USC, Toyota, and Hitachi High-technologies. After his successful tenure, he was appointed CEO of US operations in 2012. He was appointed CEO of Sider in 2019. He holds a Ph.D. in Astrophysics from Kyoto University and is a Certified Scrum Master.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.