A Study of Scala Repositories on Github
Journal Title: International Journal of Advanced Computer Science & Applications - Year 2014, Vol 5, Issue 7
Abstract
Functional programming appears to be enjoying a renaissance of interest for developing practical, “real-world” applications. Proponents have long maintained that the functional style is a better way to modularize programs and reduce complexity. What is new in this paper is we test this claim by studying the complexity of open source codes written in Scala, a modern language that unifies functional and object programming. We downloaded from GitHub, Inc., a portfolio of mostly “trending” Scala repositories that included the Scala compiler and standard library, much of them written in Scala; the Twitter, Inc., server and its support libraries; and many other repositories, several of them production-oriented and commercially inspired. In total we investigated approximately 22,000 source files with 2 millions lines of code and 223,000 methods written by hundreds of programmers. To analyze these sources, we developed a novel compiler kit that measures lines of code and adaptively learns to estimate the cyclomatic complexity of functional-object codes. The data show, first, lines of code and cyclomatic complexity are positively correlated as we expected but only weakly which we did not expect with Kendall’s t=0.258–0.274. Second, 75% of the Scala methods are straight-line, that is, they have the lowest possible cyclomatic complexity. Third, nearly 70% of methods have three or fewer lines. Fourth, the distributions of lines of code and cyclomatic complexity are both non-Gaussian (P<0.01), which is as surprising as it is interesting. These data may offer new insights into software complexity and the large-scale structure of applications including but not necessarily limited to Scala.
Authors and Affiliations
Ron Coleman, Matthew Johnson
MCMC Particle Filter Using New Data Association Technique with Viterbi Filtered Gate Method for Multi-Target Tracking in Heavy Clutter
Improving data association technique in dense clutter environment for multi-target tracking used in Markov chain Monte Carlo based particle filter (MCMC-PF) are discussed in this paper. A new method named Viterbi f...
Data Warehouse Requirements Analysis Framework: Business-Object Based Approach
Detailed requirements analysis plays a key role towards the design of successful Data Warehouse (DW) system. The requirements analysis specifications are used as the prime input for the construction of conceptual...
Mind-Reading System - A Cutting-Edge Technology
In this paper, we describe a human-computer interface (HCI) system that includes an enabler for controlling gadgets based on signal analysis of brain activities transmitted from the enabler to the gadgets. The enabler is...
Reconfigurable Efficient Design of Viterbi Decoder for Wireless Communication Systems
Viterbi Decoders are employed in digital wireless communication systems to decode the convolution codes which are the forward correction codes. These decoders are quite complex and dissipate large amount of power. With t...
Create a Virtual Mannequin Through the 2-D Image-based Anthropometric Measurement and Radius Distance Free Form Deformation
3-D human body models are used in a wild spectrum of applications, such as film and entertainment industry, that require images of human replicas, but the computer generated models of human body generally do not ad...