Table of Contents
Fetching ...

Critical Considerations on Effort-aware Software Defect Prediction Metrics

Luigi Lavazza, Gabriele Rotoloni, Sandro Morasca

TL;DR

This paper challenges the common assumption that defect-prediction effort is proportional to module size by showing that effort-aware metrics (EAMs) like PofB, NPofB, and Popt depend critically on the chosen effort driver. It provides a mathematical framework and an empirical NASA-based study comparing LOC versus McCabe complexity as effort drivers, demonstrating that EAMs can yield different, sometimes conflicting, assessments of SDP models. The results indicate that many traditional EAMs are effectively size-aware, not truly effort-aware, and that practitioners should adopt more accurate, multi-factor effort models. The work underscores the practical impact of using different effort drivers on model evaluation and selection in software defect prediction.”

Abstract

Background. Effort-aware metrics (EAMs) are widely used to evaluate the effectiveness of software defect prediction models, while accounting for the effort needed to analyze the software modules that are estimated defective. The usual underlying assumption is that this effort is proportional to the modules' size measured in LOC. However, the research on module analysis (including code understanding, inspection, testing, etc.) suggests that module analysis effort may be better correlated to code attributes other than size. Aim. We investigate whether assuming that module analysis effort is proportional to other code metrics than LOC leads to different evaluations. Method. We show mathematically that the choice of the code measure used as the module effort driver crucially influences the resulting evaluations. To illustrate the practical consequences of this, we carried out a demonstrative empirical study, in which the same model was evaluated via EAMs, assuming that effort is proportional to either McCabe's complexity or LOC. Results. The empirical study showed that EAMs depend on the underlying effort model, and can give quite different indications when effort is modeled differently. It is also apparent that the extent of these differences varies widely. Conclusions. Researchers and practitioners should be aware that the reliability of the indications provided by EAMs depend on the nature of the underlying effort model. The EAMs used until now appear to be actually size-aware, rather than effort-aware: when analysis effort does not depend on size, these EAMs can be misleading.

Critical Considerations on Effort-aware Software Defect Prediction Metrics

TL;DR

This paper challenges the common assumption that defect-prediction effort is proportional to module size by showing that effort-aware metrics (EAMs) like PofB, NPofB, and Popt depend critically on the chosen effort driver. It provides a mathematical framework and an empirical NASA-based study comparing LOC versus McCabe complexity as effort drivers, demonstrating that EAMs can yield different, sometimes conflicting, assessments of SDP models. The results indicate that many traditional EAMs are effectively size-aware, not truly effort-aware, and that practitioners should adopt more accurate, multi-factor effort models. The work underscores the practical impact of using different effort drivers on model evaluation and selection in software defect prediction.”

Abstract

Background. Effort-aware metrics (EAMs) are widely used to evaluate the effectiveness of software defect prediction models, while accounting for the effort needed to analyze the software modules that are estimated defective. The usual underlying assumption is that this effort is proportional to the modules' size measured in LOC. However, the research on module analysis (including code understanding, inspection, testing, etc.) suggests that module analysis effort may be better correlated to code attributes other than size. Aim. We investigate whether assuming that module analysis effort is proportional to other code metrics than LOC leads to different evaluations. Method. We show mathematically that the choice of the code measure used as the module effort driver crucially influences the resulting evaluations. To illustrate the practical consequences of this, we carried out a demonstrative empirical study, in which the same model was evaluated via EAMs, assuming that effort is proportional to either McCabe's complexity or LOC. Results. The empirical study showed that EAMs depend on the underlying effort model, and can give quite different indications when effort is modeled differently. It is also apparent that the extent of these differences varies widely. Conclusions. Researchers and practitioners should be aware that the reliability of the indications provided by EAMs depend on the nature of the underlying effort model. The EAMs used until now appear to be actually size-aware, rather than effort-aware: when analysis effort does not depend on size, these EAMs can be misleading.
Paper Structure (24 sections, 12 equations, 11 figures, 5 tables)

This paper contains 24 sections, 12 equations, 11 figures, 5 tables.

Figures (11)

  • Figure 1: The process.
  • Figure 2: Cost efficiency curves of the BLR SDP model that uses LOC and McCabe's complexity density as independent variables for project PC3.
  • Figure 3: Cost efficiency curves of the BLR SDP model for project MC2, when LOC and McCabe's complexity density are used as independent variables.
  • Figure 4: Optimal cost efficiency curves for project PC4, when LOC and McCabe's complexity are used as effort drivers.
  • Figure 5: Optimal cost efficiency curves for project PC5, when LOC and McCabe's complexity are used as effort drivers.
  • ...and 6 more figures