Positive Affects Inducer on Software Quality

This paper presents an early empirical study on an agile methodology (Extreme Programming) using Positive Affect metric. The question of interest is whether an agile methodology has any distinct outcome on the positive affectivity of the software developers. And whether these affects will contribute to the quality of software produced. Quantitative methods were utilized, including participative observation and simple statistical tests such as Spearman Correlation and Mann-Whitney test. The results showed that Extreme Programming has positive affectivity which leads to the increase in software quality. This study suggests that when people experience joy and mild contentment, they are more likely to be more creative over wider range of problems, become more resilient over time and are more likely to develop long-term plans and goals.


Introduction
The traditional methodologies imposed a disciplined process upon software development, with the aim of making software development more efficient in order to produce better quality systems.The detailed process places a strong emphasis on planning and was inspired by other engineering disciplines.The most frequent criticism of these methodologies is that they are bureaucratic thus slowing the development process.The second problem with these methodologies is that the requirements specifications are not flexible.In reality, it is difficult to get the software customer to identify their requirements.Even if the requirements can be identified, the business world is forever changing.As a reaction to these problems, agile methodologies evolved.Agile methodologies welcome change and unpredictability because they are more adaptive than predictive, and more people-oriented than process-oriented.Adaptive approaches are better when the requirements are uncertain or dynamic as in the new type of software application being developed nowadays.When faced with unpredictable user requirements and changes that must be accommodated during software-in-progress development, developers often experienced stressful emotions such as anxiety and depression (Sharifah Lailee, Holcombe, & Gheorge, 2006a, 2006b).

Agile Methodology
Due to rapid demand of technological changes, agile methodologies have emerged to alleviate the uncertainty of business requirements.The need to deliver quality software at economical cost is the main issue in software industry.Therefore, the Agile Alliance (2001) has expressed the values in Agile Manifesto as: Individuals and interactions over processes and tools Working software over comprehensive documentation Customer collaboration over contract negotiation Responding to change over following a plan The major agile methodologies consist of Scrum, Dynamic Systems Development Method (DSDM), Crystal Methods, Feature Driven Development (FDD), Lean Development and Extreme Programming (XP).Based on the agile manifesto, people and communication are the key ingredients towards producing quality software.Agile employs a lightweight process, which communication plays an important role over comprehensive documentation.This method focuses more on people-oriented approach, which relies on tacit or interpersonal knowledge whilst developing software.Study on agility level of these methodologies (Qumer & Henderson-Sellers, 2008) discovered that Crystal methodology has the highest degree of agility followed by XP, Scrum, and DSDM.Agility characterization were based on flexibility, speed, leanness, learning and responsive features that were calculated quantitatively.
The creators of Agile Alliance agreed that detailed project tactic should be continuously innovated in order to discover a larger set of agile software practices (Cockburn, 2007).Therefore, it is not surprising to discover different set of practices that is similar and complementary to each other.In this paper, four agile methodologies, namely XP, Scrum, Crystal and DSDM are compared according to its principles, methods and tools.
According to Strode (2005), all of the agile methodologies highlight iterative, incremental, and rapid software delivery to deal with flexible requirements in addition to active participation between the team and stakeholders.Except for Scrum and DSDM methodologies that that cater for large projects, the other methodologies are more suitable for small and medium scale project.
Agile modeling (AM) is a practice-based methodology for effective software modeling.AM is not a prescriptive process but focuses more on a portion of an overall software process needed by other agile methodologies.Most agile methods implicitly defined its model to be used, thereby indicating that working software is imperative compared to documentation.However, it is also possible to use object-oriented modeling such as Unified Modeling Language (UML) and software tools to speed up development process.These tools are needed to support the main activities such as requirements management, coding, configuration and testing activities.Each agile methodology serves different purposes and has its own principles and methods, even though they share common characteristics of agile values.Table 1 show the comparison made according to principles, methods, and tools.
For the purpose of this study, a comparison between an agile methodology (XP) and formal methodology (RUP) was conducted.The study focus on the agility of each software methodology to induce positive affect on each member of SE teams and how these affects contribute to the level of software quality.

Extreme Programming
Beck (2000) introduces XP as a solution to the problems encountered by the formal methods.The XP methodology was created to address requirement changes and project risk.XP begins with 4 values; Communication, Simplicity, Feedback and Courage.It then builds up to practices that XP projects should follow.In XP, features that provide the most business value to the customer must be developed first because the real goal of this approach is to deliver the software that is needed when it is needed.Requirements are written as user stories, which are chunks of functionality that are valuable to the customers.Chunking is a technique in cognitive learning strategy that allows information to be broken down into smaller and meaningful collection of knowledge.Through the use of story cards, it is easier for developers to group different stories according to main functions.Chunking assist developers because human has limited memory capacity and often have difficulty to memorize a large amount of functions or information (Mazni, Sharifah Lailee, & Holcombe, 2009).XP encourages communication by having developers collectively own all codes and work in pairs.Collective code ownership considers code as belonging to the team and not to the individual developers, thereby encourages every developer to contribute new ideas to all segments of the project.Pair programming requires two developers to sit side by side in front of a computer.One person types and thinks tactically about the methods being created, while the other thinks strategically about how the methods fit into the class.Pair programming changes the environment from criticism and competition to learning and cooperation thus improving group cohesiveness and communication.Complex requirements must be simplified to enhance understanding between team members.XP simple design evolves through constant refactoring, which is guided by suitable metaphor and implemented in accordance to common coding standards.Fowler, Beck, Brant, Opdyke, & Roberts (1999) defined refactoring as the removal of redundant or unused functionality and the restructuring of obsolete designs in order to improve smelly codes.Tong (2004) considered too many comments as useless and further suggested refactoring of these comments into codes.System metaphor is a narrative that everyone (customer, programmer and managers) can associate with when discussing new functionality.The reason for using a metaphor is to achieve a common vision and shared vocabulary.On-site customer is a practice which requires the customer to sit with the development team on a full-time basis.Holcombe (2002) is more realistic by suggesting regular visits and meetings at both the development site and the business site.The humanistic aspect of the communication and the simplicity aspect promote good teamwork because it is an important towards developing quality software.

Rational Unified Process
Rational Unified Process (RUP) is a software development methodology originated by Rational Software, IBM (Dennis, Wixom, & Tegarden, 2005;Runeson & Greberg, 2004).RUP methodology claimed to be a heavyweight methodology due to its demands to produce extensive documentation.This approach is a use case driven and requires tool to support the software development activities.Unlike agile (XP), RUP emphasizes on specific roles that tailored for a particular project.Examples of these roles are team leader, programmer, user interface designer, software tester and quality assurance.RUP has four distinct phases, which are inception, elaboration, construction and transition phase (Bennet, McRobb, & Farmer, 2006).Although RUP has formal phases, it allows software development teams to design and develop software in iterative and incremental manner.

Positive affect
Past research has shown that a positive affect induction leads to a greater cognitive flexibility and facilitates creative problem solving across a broad range of settings.Research works by Carnevale & Isen (1986), Aspinwall (1998), Ashby, Isen, & Turken (1999) and Isen (2001), suggest that positive affect increases a person's ability to organize ideas in multiple ways, to access alternative perspectives and also to improve performance in several tasks that are typically used as indicators of creativity or innovative problem solving.In a study of the role of affect on human life, Norman and colleagues (Norman, Ortony, & Russell, 2003) show that affect makes humans smart because affect is always passing judgments and presenting them with immediate information about the world.The affective signals work through neurochemicals, bathing the relevant brain centres and changing the way humans perceive, decide, and react.These neurochemicals change the parameters of thought, adjusting such things as whether reason is primarily 'depth first' (focused, not easily distracted) or 'breadth first' (creative, out of the box thinking, but easily distractible).
It is the intention of this paper to discuss Extreme Programming (XP) as a positive affect inducer and to discuss the findings of the possible impact of the selected XP practices on the software quality.To achieve this, a comparison study was conducted on the software engineering teams consisted of third year students at University Utara Malaysia (UUM).Findings revealed that the XP methodology does have an impact on the positive affectivity and level of software quality.

Method
A replicated study (Sharifah Lailee et al., 2006b) were carried out in UUM, to determine empirically, whether teams using XP methodology would experience higher positive affectivity than the teams using the Rational Unified Process (RUP) approach.To measure the developers' state of the positive affect, the positive affect scale of the Positive and Negative Affect Schedule (PANAS) was used.Positive affect was induced by introducing and requiring the XP methodology to be used by half of the development teams.The studies do not include the negative affect because previous research has shown that positive affect can operated as a single construct, indicating that the fluctuation of the positive affectivity, has no effect on the negative affectivity of a person (Anderson & Thompson, 2004).
The validity and reliability of PANAS scale has been demonstrated by other studies (Watson & Clerk, 1997;Watson, Pennebaker, & Folger, 1987;Watson & Tellegen, 1985).The Positive Affect scale showed a satisfactory internal consistency coefficient, Cronbach alpha = 0.78 during the first reading (Week 2), Cronbach alpha = 0.89 during the second reading (Week 6) and Cronbach alpha = 0.87 during the third reading (Week 15).At the beginning of the study, Independent sample t-test was used to compare the total mean score for Positive Affect variables and the result showed no significant difference between Formal teams [N=28 , Mean Score (M) =34.12,Standard Deviation (SD)=4.77]and Agile (XP) teams [N=30, Mean Score (M) =34.53,Standard Deviation (SD)=4.41].
At the end of Week 15, each information system projects were graded by teams of evaluators which consisted of project client and a lecturer.The mean scores awarded by both evaluators were assessed.The following graph shows grades achieved by both teams according to the projects.The Mann-Whitney non parametric statistical test was used to compare the mean scores and the results showed significant differences in the mean scores for the Formal teams [M=21.09,SD=2.91] and the Agile (XP) teams [M=23.96,SD=1.31].The graph indicates that teams using Agile (XP) approach were awarded higher score than Formal (RUP) teams (see Figure 2).
In this study, XP methodology was chosen as a positive inducer because of the existence of several XP practices that warrant feedback to the developers.Positive feedback one's performance has been known as a positive affect inducer (Estrada, Isen, & Young, 1997;Sharifah Lailee et al., 2006a).The XP practices associated with feedback seeking are simple design, pair programming, continuous testing, continuous integration and frequent review (release).
Studies by Aspinwall (1998) and Muraven, Tice, & Baumeister (1998) noted that people must have a surplus of resources such as time, energy and attention to engage in a proactive behaviour.Using XP approach, the developers experienced a surplus of time during coding because less time was engaged in the designing phase.Using simplified design XP developers are actually releasing the stressful task of creation, thus liberating the mind to be more creative and innovative.By reducing the technical aspect of design, the mind was able to approach the problem solving task through a breadth first approach.Design is only an early manifestation of ideas, whereas the coding process allows the developers to realize their idea in a more concrete way.This approach is considered as a positive affect inducer because it allows feedback on the design through the programming code.The ability to see the results and identify the flaws in the design allows the developers to be more creative in the next part of the system.This is the reason why simple design can accommodate flexible requirements because the process of creating part of the system in this manner allows developers to be more innovative in the problem solving process.It was observed that the practice of pair programming started with initial socializing amongst the pair thus creating a positive mood before any formal programming commenced.The ability to discuss the advantages and disadvantages of certain coding ideas enables the pair to seek improvements and avoid specific weaknesses.Studies on pair programming have provided the evidence about the benefits of pair programming (Coman, Sillitti, & Succi, 2008;Succi, Marchesi, Pedrycz, & Williams, 2002;Williams, 2002).With pair programming practice, positive affect is induced through early socializing, more attention and immediate feedback amongst the pair.
Continuous testing allows feedback on the developed code.In the normal software testing domain, testing is usually left at the end of the development cycle thus leaving a very mood which is experienced and the attention of the two developers allow the pair to engage in a more short time for complete testing.In this situation, often the developers were faced with products that have too many defects, as the bugs were discovered too late.The benefit of testing as the software is developed is that the developers are always certain that the software developed is always test compliant.Continuous testing is a practice that is structured so that different levels of testing can be conducted as the solution is being built.In the study by Trope & Pomerantz (1998), participants in whom positive affect has been induced showed greater interest in the part of the test they had failed than did neutral mood participants.The emphasis of the continuous testing enables the developers to feel more confident about the correctness of the code and therefore bolster their confidence and self-esteem.
Continuous integration is another feedback seeking practice, which allows the developers to address performance problems earlier in the development process.The more frequently the developers were able to test the integrated system, the more often they were able to check the functional integrity of the application as some problems do not manifest themselves until they are in the integration environment, such as when a database application is finally tested in a genuine load.The ability to address the performance problems early and to continuously improve the system allows the developers to enjoy a level of self regard or positive affect.Developers using this practice had the advantage of improving their self-esteem continuously, as they worked to perfect the functionality of the integrated system.Frequent release (review) is another practice that commands feedback.Feedback from the client be it positive or negative, is also a positive affect inducer.Accumulating evidences suggest that positive affect can create an increased interest in information about one's liabilities.A study by Trope & Neter (1994) has shown that prior positive experience subsequently increased the interest in feedback of high rather than low self-relevance, even when the feedback was expected to diagnose weaknesses rather than strengths.

Conclusion
In this study, even though there was no significant difference in positive affect between the methodologies, it is interesting to observe the impact of the XP on the positive affectivity of the developers which result in higher score being awarded to the agile teams.The teams using a more flexible approach, such as the XP methodology, were able to incorporate the constant changes made by the clients and thus able increase their positive mood.When a person experiences a positive affect, they show a greater preference for a larger variety of actions and are able to see and think of more possibilities and options to solve whatever problem is faced.People with a positive affect are more likely to take action because they are proactive.This study suggests that when people experience joy and mild contentment, they are more likely to think of a wider range of actions, become more resilient over time and are more likely to develop plans and goals.

Table 1 .
Comparison of four agile methodologies according to its principles, methods and tools

Table 2 .
Descriptive statistics of positive affectivity of both teams (UUM 2008) Figure 1.Line graph of the positive affect of the two teams before treatment (week 2) and after treatments (week 6 and week15) Figure 2. Bar graph showing teams performance according to project