An Improvement of Cohesion Metrics using Weights of Variables
Cheol-Hyun Park, Sung-Tae Ryu, Eunseok Lee · Jeongbo gwahaghoe nonmunji. so'peuteuweeo mich eung'yong · 2011
Software quality measurement in software engineering is essential. Cohesion of software quality metrics is how tightly bound or related its internal elements are to one another. Cohesion is used for various purposes, such as modularization, reusability, fault-proneness, and change-proneness. Existing cohesion metrics only use the number of pairs of methods with shared variables, and do not consider the weight of the variables. Therefore, they cannot measure cohesion metrics accurately. In this paper, we propose a new approach to improve cohesion metrics using the measured weight of variables by PCA (Principal Component Analysis). We compare our proposed approach with existing approaches in 4 cohesion metrics applied with 2 open source projects. The correlation coefficient between change-proneness and improved cohesion metrics increased by 20% on average compared to existing cohesion metrics. Thus, improved cohesion metrics can measure software quality more accurately.