Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 6 Next »

Purpose

Duplicated Lines (%) shows a percentage of duplicated lines in the project code compared to a total amount of lines of code (LOC) on the project.

How metric helps

Code duplicates will lead to duplicated bugs and coding standards breaches, etc. Therefore increasing duplicated lines percentage can indicate a lack of good inheritance structure or abstraction.

How it works

Chart Overview

Duplicate code lines are shown in % (Axis Y) and distributed over time (Axis Y) on the chart.

Each project child unit (can be set up in Project Configuration Wizard) in the legend is clickable, and shows/hides its percentage on the chart once clicked. The chart also adjusts a scale automatically to better fit the series shown on a screen.

2017-10-23_16-30-33.png

Calculation Formula

Duplicated Lines (%) = Duplicated Lines / LOC * 100%,

where

Duplicated Lines - a number of duplicates

LOC - number of all code lines


RAG thresholds: Red > 20%, Amber > 5%, otherwise Green.

Data Source

Data for the metric can be collected from Sonar or any other project tracking/engineering tool.


  • No labels