Empirical study of abnormality in local variables and its application to fault‐prone Java method analysis

Empirical study of abnormality in local variables and its application to fault‐prone Java method analysis
复制标题

局部变量异常的实证研究及其在易错Java方法分析中的应用

DOI:
10.1002/smr.2220
复制
发表时间:
2020
期刊:
Journal of Software: Evolution and Process
影响因子:
--
通讯作者:
Kawahara Minoru
Kawahara Minoru
中科院分区:
--
文献类型:
--
作者:
Aman Hirohisa;Amasaki Sousuke;Yokogawa Tomoyuki;Kawahara Minoru

文献摘要

参考文献

相似文献

程序员熟悉局部变量,在许多情况下,他们可以自由定义他们使用的局部变量。因此,这些变量的属性是非常不同的,这可能会导致代码质量的变化。虽然变量是按照编码惯例命名的,但从经验的角度来看,以下事项没有得到太多的关注:自动判断局部变量是否“异常”,并确定异常变量的有害影响。本研究针对局部变数在名称、类型、作用域上的变化趋势,提出利用马氏距离来评估其异常性。实证研究需要从八个开放源码软件项目中收集本地变量,文件报告了以下调查结果:(a)变量名称根据其类型的变化趋势;(B)大多数变量的名称较短,范围较窄,名称通常是一个单词或其缩写;(c)具有异常变量的方法比仅包含正常变量的方法更容易出错的可能性大约高1.4倍;(d)所提出的异常度量可以用于基于随机森林的易出错方法分析模型。
Programmers are familiar with local variables, and in many cases, they can freely define the local variables they use. Thus, the properties of these variables are widely diverse, and this may cause variations in the quality of code. Although variables are named in accordance with coding conventions, the following matters have not received much attention from an empirical viewpoint: automatically deciding whether a local variable is “abnormal” and determining the harmful effect of an abnormal variable. This study focuses on the trends in the name, type, and scope of local variables, then proposes the use of the Mahalanobis distance to evaluate their abnormality. The empirical study entailed collecting local variables from eight open‐source software projects, and the paper reports the following findings: (a) the trend in the variation of the names of variables according to their type; (b) the majority of variables have short names with narrow scopes, where a name is often a word or an abbreviation thereof; (c) methods with an abnormal variable are approximately 1.4 times more likely to be fault prone than methods that contain only normal variables; (d) the proposed abnormality metric can be useful in a random forest‐based fault‐prone method analysis model.
Historage:Java 的细粒度版本控制系统
DOI: 10.1145/2024445.2024463
发表时间: 2011
影响因子: 23.6
作者:
Hideaki Hata;O. Mizuno;T. Kikuno
通讯作者: T. Kikuno
用于评估标识符分割器的数据集
DOI: 10.1109/msr.2013.6624055
发表时间: 2013
期刊: 2013 10th Working Conference on Mining Software Repositories (MSR)
影响因子: --
作者:
D. Binkley;Dawn J Lawrie;L. Pollock;Emily Hill;K. Vijay
通讯作者: K. Vijay
用于异常检测的马哈拉诺比斯距离图方法
DOI: 10.4225/75/57b66f5a3477b
发表时间: 2010
期刊: --
影响因子: --
作者:
Aruna Jamdagni;Aruna Jamdagni;Zhiyuan Tan;P. Nanda;Xiangjian He;R. Liu
通讯作者: R. Liu
软件质量建模:类噪声对随机森林分类器的影响
DOI: 10.1109/cec.2008.4631321
发表时间: 2008
期刊: 2008 IEEE Congress on Evolutionary Computation (IEEE World Congress on Computational Intelligence)
影响因子: --
作者:
A. Folleco;T. Khoshgoftaar;J. V. Hulse;Lofton A. Bullard
通讯作者: Lofton A. Bullard
干净的代码:敏捷软件工艺手册
DOI: --
发表时间: 2008
期刊:
影响因子: --
作者:
Robert C. Martin
通讯作者: Robert C. Martin