Authors:
Mário Hozano
1
;
Nuno Antunes
2
;
Baldoino Fonseca
3
and
Evandro Costa
3
Affiliations:
1
Federal University of Campina Grande, Brazil
;
2
University of Coimbra, Portugal
;
3
Federal University of Alagoas, Brazil
Keyword(s):
Code Smell, Machine Learning, Experiment.
Related
Ontology
Subjects/Areas/Topics:
Artificial Intelligence
;
Data Mining
;
Databases and Information Systems Integration
;
Enterprise Information Systems
;
Information Systems Analysis and Specification
;
Sensor Networks
;
Signal Processing
;
Soft Computing
;
Software Engineering
;
Software Metrics and Measurement
Abstract:
Code smells indicate poor implementation choices that may hinder the system maintenance. Their detection is
important for the software quality improvement, but studies suggest that it should be tailored to the perception
of each developer. Therefore, detection techniques must adapt their strategies to the developer’s perception.
Machine Learning (ML) algorithms is a promising way to customize the smell detection, but there is a lack
of studies on their accuracy in detecting smells for different developers. This paper evaluates the use of ML-algorithms
on detecting code smells for different developers, considering their individual perception about
code smells. We experimentally compared the accuracy of 6 algorithms in detecting 4 code smell types for 40
different developers. For this, we used a detailed dataset containing instances of 4 code smell types manually
validated by 40 developers. The results show that ML-algorithms achieved low accuracies for the developers
that participated
of our study, showing that are very sensitive to the smell type and the developer. These
algorithms are not able to learn with limited training set, an important limitation when dealing with diverse
perceptions about code smells.
(More)