Empirical Evaluation of Hunk Metrics as Bug Predictors

  • Authors:
  • Javed Ferzund;Syed Nadeem Ahsan;Franz Wotawa

  • Affiliations:
  • Institute for Software Technology, Technische Universität Graz, Austria;Institute for Software Technology, Technische Universität Graz, Austria;Institute for Software Technology, Technische Universität Graz, Austria

  • Venue:
  • IWSM '09 /Mensura '09 Proceedings of the International Conferences on Software Process and Product Measurement
  • Year:
  • 2009

Quantified Score

Hi-index 0.00

Visualization

Abstract

Reducing the number of bugs is a crucial issue during software development and maintenance. Software process and product metrics are good indicators of software complexity. These metrics have been used to build bug predictor models to help developers maintain the quality of software. In this paper we empirically evaluate the use of hunk metrics as predictor of bugs. We present a technique for bug prediction that works at smallest units of code change called hunks. We build bug prediction models using random forests, which is an efficient machine learning classifier. Hunk metrics are used to train the classifier and each hunk metric is evaluated for its bug prediction capabilities. Our classifier can classify individual hunks as buggy or bug-free with 86 % accuracy, 83 % buggy hunk precision and 77% buggy hunk recall. We find that history based and change level hunk metrics are better predictors of bugs than code level hunk metrics.