Volume 13, Number 3

Complexity Metrics for Statechart Diagrams


Ann Wambui King’ori1, 2, Geoffrey Muchiri Muketha1 and Elyjoy Muthoni Micheni3, 1Murang’a University, Kenya, 2Nkabune Technical Training Institute, Kenya, 3Technical University of Kenya


Model-Driven Development and the Model-Driven Architecture paradigm have in the recent past been emphasizing on the importance of good models. In the Object-Oriented paradigm one of the key artefacts are the Statechart diagrams. Statechart diagrams have inherent complexity which keeps increasing every time the diagrams are modified, and this complexity poses problems when it comes to comprehending the diagrams. Statechart diagrams provide a foundation for analysing the dynamic behaviour of systems, and therefore, their quality should be maintained. The aim of this study is to develop and validate metrics for measuring the complexity of UML Statechart diagrams. This study used design science which involved the definition of metrics, development of a metrics tool, and theoretical and empirical validation of the metrics. For the measurement of the cognitive complexity of statechart diagrams, this study proposes three metrics. The defined metrics were further used to calculate the complexity of two sample statechart diagrams and found relevant. Also, theoretical validation of the defined metrics was done using the Weyuker’s nine properties and revealed they are mathematically sound. Empirical validations were performed on the metrics and results indicate that all the three metrics are good for the measurement of the cognitive complexity of statecharts.


UML Diagrams, Statechart diagrams, Software metrics, complexity measures, Theoretical validations, Empirical validations.