SlideShare a Scribd company logo
1 of 72
On the Relationship Between Change
Coupling and Software Defects
Marco D’Ambros
Michele Lanza
Romain Robbes

                 REVEAL @ University of Lugano, CH
Change Coupling

       t1       t2       t3      t4                                              t5                                                                                            t6
 c1

 c2
Time

                                                  Ball                                in Proceedings of the International Conference on Software Maintenance 1998 (ICSM ’98)            Gall                          1/10




                                                 199                                                 Detection of Logical Coupling Based on Product Release History
                                                                                                                                                                                       199
                                                     7                                                                                                                                     8
                                                                                                                              Harald Gall, Karin Hajek, and Mehdi Jazayeri




 “The implicit relationship of
                                                                                                                       Technical University of Vienna, Distributed Systems Group
                                                                                                                       Argentinierstrasse 8/184-1, A-1040 Wien, Austria, Europe
                                                                                                                              {gall,hajek,jazayeri}@infosys.tuwien.ac.at


                                                 Requirements
                                                                                                                 Abstract                                                consists of 10 million lines of code (MLOC) per
                                                                                      Code-based metrics such as coupling and cohesion are                               system release.
                                                   Version                            used to measure a system’s structural complexity. But
                                      Software     Control      Implementation                                                                                      2. Such measures do not reveal all dependencies (e.g.
                                      Process                    Technology           dealing with large systems—those consisting of several
                                                   History
                                                                                      millions of lines— at the code level faces many prob-                            dynamic relations). In fact, some dependencies are
                                                                                      lems. An alternative approach is to concentrate on the                           not written down either in documentation or in the
                                                                                      system’s building blocks such as programs or modules                             code. The software engineer just “knows” that to
                                                 Developers
                                                                                      as the unit of examination. We present an approach that                          make a change of a certain type, he or she has to
                                                                                                                                                                       change a certain set of modules.




  two software artifacts that
                                                                                      uses information in a release history of a system to un-
                                                                                      cover logical dependencies and change patterns among                            We may say that such code-based measures reveal
                                                                                      modules. We have developed the approach by working                          syntactic dependencies and what we are really interested
                                                                                      with 20 releases of a large Telecommunications Switch-                      in is logical dependencies among modules. The purpose
                                                                                      ing System. We use release information such as version                      of this paper is to present an approach to uncover such
                                                                                      numbers of programs, modules, and subsystems together                       logical dependencies by analyzing the release history of a
                                                                                      with change reports to discover common change behav-                        system. Release histories contain a wealth of information
                                                                                      ior (i.e. change patterns) of modules. Our approach                         about the software structure. The task is just to analyze
                                                                                      identifies logical coupling among modules in such a way                     them and uncover the information.
                                                                                      that potential structural shortcomings can be identified                        In particular, we can analyze release histories to look
                                                                                      and further examined, pointing to restructuring or                          for patterns of change: are there some modules that are
                                                                                      reengineering opportunities.                                                always changed together in a release? Are there sequen-
                                                                                                                                                                  tial dependencies such as if module A is changed in one
                                                                                      1 Introduction                                                              release, module B is changed in the next release? And so




 frequently change together”
                                                                                                                                                                  on.
                                                                                         Large software systems are continuously modified and
                                                                                                                                                                      We have developed a technique called CAESAR for
                                                                                      increase in size and complexity. After many enhance-
                                                                                                                                                                  detecting such patterns. We have applied the technique
                                                                                      ments and other maintenance activities, modifications
                                                                                                                                                                  to a large system with a 20-release history and identified
                                                                                      become hard to do. Therefore, methods and techniques
                                                                                                                                                                  potential dependencies among modules. To validate the
                                                                                      are needed to restructure or even reengineer a system
                                                                                                                                                                  accuracy of these dependencies identified by our tech-
                                                                                      into a more maintainable form.
                                                                                                                                                                  nique, we examined change reports that contain specific
                                                                                         To evaluate the impact of changes, we need to under-
                                                                                                                                                                  change information for a release. The results have shown
                                                                                      stand the relationships, that is, dependencies among
                                                                                                                                                                  that this approach is promising in identifying “logical”
                                                                                      modules that compose the system. Current methods of
                                                                                                                                                                  couplings among modules across several releases.
                                                                                      identifying dependencies are based on metrics such as
                                                                                                                                                                      Our technique reveals hidden dependencies not evi-
                                                                                      coupling and cohesion measures [6,17]. These measures
                                                                                                                                                                  dent in the source code and identifies modules that are
                                                                                      identify dependencies among modules by the existence of
                                                                                                                                                                  candidates for restructuring. The technique requires very
                                                                                      such relationships as procedure calls or “include” direc-
                                                                                                                                                                  little data to be kept for each release of a system. Rather
                                                                                      tives. There are two basic issues with these measures:
                                                                                                                                                                  than dealing with millions of lines of code, it works with
                                                                                                                                                                  structural information about programs, modules, and
                                                                                       1. These measures are based on source code which is
                                                                                                                                                                  subsystems, together with their version numbers and
                                                                                          usually very large. In our case study the source code
Previous research on Change Coupling

                        Gall et. al., IWPSE ’03

                        Change coupling
                        points to architectural
                        weaknesses
Previous research on Change Coupling

                        Pinzger et. al., SoftVis ’05

                        Change coupling
                        facilitates the detection
                        of refactoring candidates
Previous research on Change Coupling

                        Beyer et. al., WCRE ’06

                        Change coupling helps
                        the comprehension of
                        system modularization
Previous research on Change Coupling

                        D’Ambros et. al., TSE ‘09

                        Change coupling helps
                        in spotting misplaced
                        software components
Previous research on Change Coupling

                        D’Ambros et. al., TSE ‘09

           What about Changeare helps
                               coupling
                      softw misplaced
                      in spotting
                defectsoftware components
                      s?
Previous research on Change Coupling

                          D’Ambros et. al., TSE ‘09

          What abonge ofowpcoupling helps
                        Change
                     ut in c t u aling
                  ha s spottinge  r misplaced
      Q 1 Does c
                 defectft? are defects?
                        sw
                     so software components
      correlate with
Previous research on Change Coupling

                          D’Ambros et. al., TSE ‘09

          What abonge ofowpcoupling helps
                        Change
                     ut in c t u aling
                  ha s spottinge  r misplaced
      Q 1 Does c
                 defectft? are defects?
                        sw
                     so software components
      correlate with
      Q2 Does it improve existing
      defect prediction techniques?
Change Coupling metrics

  Class   #defects   ?
  Foo        1       7
  Bar       10       4
  Boo        2       0
Change Coupling metrics
                          Class level change
  Class   #defects   ?    coupling metrics
  Foo        1       7
  Bar       10       4
  Boo        2       0
n-coupled classes
         t1       t2      t3       t4      t5         t6
    c1

    c2

    c3

    c4

    c5


   2 classes are n-coupled if they changed together
                    at least n times
n-coupled classes      n=4

         t1       t2         t3    t4      t5         t6
    c1

    c2

    c3

    c4

    c5


   2 classes are n-coupled if they changed together
                    at least n times
n-coupled classes      n=4

         t1       t2         t3    t4      t5         t6
    c1

    c2

    c3

    c4

    c5


   2 classes are n-coupled if they changed together
                    at least n times
n-coupled classes      n=4

         t1       t2         t3    t4      t5         t6
    c1

    c2

    c3

    c4

    c5


   2 classes are n-coupled if they changed together
                    at least n times
n-coupled classes      n=5

         t1       t2         t3    t4      t5         t6
    c1

    c2

    c3

    c4

    c5


   2 classes are n-coupled if they changed together
                    at least n times
NOCC(class, n): Number Of Coupled Classes

               NOCC(c2, 4) = 1

          t1     t2     t3       t4   t5    t6
1    c1

     c2

     c3

     c4

     c5
NOCC(class, n): Number Of Coupled Classes

               NOCC(c2, 4) = 1 + 1

          t1     t2     t3     t4    t5     t6
1    c1

     c2

     c3

     c4

 1   c5
SOC(class, n): Sum Of Coupling

               SOC(c2, 4) =

          t1    t2     t3        t4   t5   t6
     c1

     c2

     c3

     c4

     c5
SOC(class, n): Sum Of Coupling

                   SOC(c2, 4) = 4

              t1    t2     t3       t4       t5       t6
          1                     2        3        4
     c1

     c2

     c3

     c4

     c5
SOC(class, n): Sum Of Coupling

                  SOC(c2, 4) = 4 + 5

         t1        t2     t3       t4       t5       t6
    c1

    c2

    c3

    c4

    c5
              1                2        3        4        5
Metrics with linear and exponential decay
EWSOC: Exponentially Weighted Sum Of Coupling
LWSOC: Linearly Weighted Sum Of Coupling



     k=5            k=4     k=3     k=2          k=1
     t1      t2      t3      t4       t5          t6
c1

c2

                              Current release
                                                Time
Metrics with linear and exponential decay
EWSOC: Exponentially Weighted Sum Of Coupling
LWSOC: Linearly Weighted Sum Of Coupling

           Exponential = 1
               weight    24
               Linear = 1
               weight   5
     k=5                      k=4   k=3    k=2          k=1
     t1           t2          t3    t4       t5          t6
c1

c2

                                     Current release
                                                       Time
Metrics with linear and exponential decay
EWSOC: Exponentially Weighted Sum Of Coupling
LWSOC: Linearly Weighted Sum Of Coupling
                                          Exponential = 1
           Exponential = 1                    weight    20
               weight    24
                                              Linear = 1
               Linear = 1                     weight   1
               weight   5
     k=5                      k=4   k=3      k=2             k=1
     t1           t2          t3    t4         t5            t6
c1

c2

                                     Current release
                                                        Time
Experiments
     Methodology
 Q1 Correlation analysis

 Q2 Regression analysis
Experiments
     Methodology
 Q1 Correlation analysis
                                   Analyzed systems
 Q2 Regression analysis                       #classes #transactions
                                   ArgoUML      2,197        15,257
                           Eclipse JDT Core     1,193        13,186
                                      Mylyn     3,050         9,373
Experiments
     Methodology
 Q1 Correlation analysis
                                   Analyzed systems
 Q2 Regression analysis                       #classes #transactions
                                   ArgoUML      2,197        15,257
                           Eclipse JDT Core     1,193        13,186
                                      Mylyn     3,050         9,373
     Change coupling
     NOCC
     SOC
     EWSOC
               function
     LWSOC     of n
Experiments
     Methodology
 Q1 Correlation analysis
                                   Analyzed systems
 Q2 Regression analysis                       #classes #transactions
                                   ArgoUML      2,197        15,257
                           Eclipse JDT Core     1,193        13,186
                                      Mylyn     3,050         9,373
     Change coupling
     NOCC
                                        Baseline
                                    6 CK metrics
     SOC                                 +
     EWSOC                          5 OO metrics
               function
     LWSOC     of n                      +
                                    # changes
Correlation analysis



      Q1 Does   change coupling
      correlate w ith software defects?
Correlation analysis



      Q1 Does   change coupling
      correlate w ith software defects?

      Q1* Does it correlate more
      with severe software defects?
Eclipse JDT Core - All bugs
   Spearman correlation




                              n
Eclipse JDT Core - All bugs
          Spearman correlation
0.9


0.8


0.7


0.6


0.5


0.4

                                                     n
0.3
      1         3        5       8   10   15   20   30
Eclipse JDT Core - All bugs
          Spearman correlation
0.9


0.8


0.7


0.6


0.5
                        Fan out
0.4

                                                      n
0.3
      1         3        5        8   10   15   20   30
Eclipse JDT Core - All bugs
          Spearman correlation
0.9                                             #Changes

0.8


0.7


0.6


0.5
                        Fan out
0.4

                                                           n
0.3
      1         3        5        8   10   15   20     30
Eclipse JDT Core - All bugs
          Spearman correlation
0.9                                                #Changes

0.8
                SOC                                     NOCC
0.7
                    LWSOC             EWSOC
0.6


0.5
                        Fan out
0.4

                                                               n
0.3
      1         3        5        8   10      15   20      30
Eclipse JDT Core - All bugs
          Spearman correlation
0.9                                             #Changes

0.8          Q1 Chan   ge coupling does
0.7
               SOC
             correlate w ith software defects, NOCC
                LWSOCan all source code
             more th             EWSOC
0.6
             metrics, wor se than #changes
0.5
                        Fan out
0.4

                                                           n
0.3
      1         3        5        8   10   15   20     30
Eclipse JDT Core - All bugs
          Spearman correlation
0.9                                            #Changes

0.8          Q1 Chan   ge coupling does
0.7
               SOC
             correlate w ith software defects, NOCC
                LWSOCan all source code
             more th             EWSOC
0.6
             metrics, wor se than #changes
0.5
               DecayFan outdels do not wor k
                      mo
0.4

                                                          n
0.3
      1         3        5       8   10   15   20     30
Mylyn - Severe Bugs
   Spearman correlation




                          n
Mylyn - Severe Bugs
           Spearman correlation
0.40


0.37


0.33


0.30


0.27


0.23

                                                      n
0.20
       1         3        5       8   10   15   20   30
Mylyn - Severe Bugs
           Spearman correlation
0.40


0.37


0.33

                                                     LOC
0.30


0.27


0.23

                                                           n
0.20
       1         3        5       8   10   15   20     30
Mylyn - Severe Bugs
           Spearman correlation
0.40                                            #Changes

0.37


0.33

                                                     LOC
0.30


0.27


0.23

                                                           n
0.20
       1         3        5       8   10   15   20     30
Mylyn - Severe Bugs
           Spearman correlation
0.40                              SOC               #Changes

0.37


0.33                     EWSOC               NOCC
                         LWSOC                           LOC
0.30


0.27


0.23

                                                               n
0.20
       1         3        5       8     10     15   20     30
Mylyn - Severe Bugs
           Spearman correlation
0.40                              SOC             #Changes

0.37


                Q1*  Cha   nge c
                        EWSOC
                                ouplingNOCCrelates
                                        cor
                            severe defects, but is LOC
0.33

                less withLWSOC
0.30
                bette  r than all source code
0.27            m  etrics and #changes
0.23

                                                             n
0.20
       1         3        5       8     10   15   20     30
Regression Analysis



    Q2 Does cha    nge coupling improve
    defect pr ediction techniques?
Regression Analysis



    Q2 Does cha    nge coupling improve
    defect pr ediction techniques?

    Q2*  Is the improvement greater
    for severe defects?
Regression Models

                    #changes
                    NOCC(n)
Source code
  metrics     +     SOC(n)
                    EWSOC(n)
                    LWSOC(n)
Regression Models

                    #changes   NOCC all
                    NOCC(n)    (for all n)
Source code
  metrics     +     SOC(n)
                    EWSOC(n)
                    LWSOC(n)
Regression Models

                    #changes     NOCC all
                    NOCC(n)      (for all n)
Source code
  metrics     +     SOC(n)
                    EWSOC(n)   All CC measures
                    LWSOC(n)       (for all n)
Regression Models

                    #changes          NOCC all
                    NOCC(n)           (for all n)
Source code
  metrics     +     SOC(n)
                    EWSOC(n)       All CC measures
                    LWSOC(n)           (for all n)



           W  e measure explanative and
          predictive power of the models
Eclipse JDT Core - Major Bugs - Explanative Power
   R²




                                               n
Eclipse JDT Core - Major Bugs - Explanative Power
           R²
0.85


0.73


0.60


0.48


0.35


0.23

                                               n
0.10
       1        3   5   8   10    15    20    30
Eclipse JDT Core - Major Bugs - Explanative Power
           R²
0.85


0.73


0.60


0.48


0.35


0.23
                        Metrics
                                                  n
0.10
       1        3   5      8      10   15   20   30
Eclipse JDT Core - Major Bugs - Explanative Power
           R²
0.85                                   Metrics + #Changes

0.73


0.60


0.48


0.35


0.23
                        Metrics
                                                            n
0.10
       1        3   5      8      10    15      20      30
Eclipse JDT Core - Major Bugs - Explanative Power
           R²
0.85                                            Metrics + #Changes

0.73
                    Metrics + SOC
0.60


0.48                         Metrics LWSOC    Metrics + NOCC

0.35

                                              Metrics EWSOC
0.23
                               Metrics
                                                                     n
0.10
       1        3        5          8    10      15      20      30
Eclipse JDT Core - Major Bugs - Explanative Power
           R²
0.85                                            Metrics + #Changes
                                                        NOCC All
0.73
                    Metrics + SOC
0.60


0.48                         Metrics LWSOC    Metrics + NOCC

0.35

                                              Metrics EWSOC
0.23
                               Metrics
                                                                     n
0.10
       1        3        5          8    10      15      20      30
Eclipse JDT Core - Major Bugs - Explanative Power
           R²                                   All CC measures
0.85                                            Metrics + #Changes
                                                         NOCC All
0.73
                    Metrics + SOC
0.60


0.48                         Metrics LWSOC    Metrics + NOCC

0.35

                                              Metrics EWSOC
0.23
                               Metrics
                                                                     n
0.10
       1        3        5          8    10      15       20      30
Eclipse JDT Core - All Bugs - Predictive Power
   Spearman correlation




                                                 n
Eclipse JDT Core - All Bugs - Predictive Power
           Spearman correlation
0.67


0.61


0.55


0.49


0.42


0.36

                                                      n
0.30
       1         3        5       8   10   15   20   30
Eclipse JDT Core - All Bugs - Predictive Power
           Spearman correlation
0.67


0.61


0.55


0.49


0.42

                                                Metrics
0.36

                                                           n
0.30
       1         3        5       8   10   15   20        30
Eclipse JDT Core - All Bugs - Predictive Power
           Spearman correlation
0.67


0.61                                       Metrics + #Changes

0.55


0.49


0.42

                                                    Metrics
0.36

                                                                n
0.30
       1         3        5       8   10    15      20        30
Eclipse JDT Core - All Bugs - Predictive Power
           Spearman correlation
0.67

                                  Metrics + SOC
0.61                                              Metrics + #Changes

0.55


0.49
                     Metrics LWSOC


0.42                                              Metrics + NOCC
                              Metrics EWSOC                Metrics
0.36

                                                                       n
0.30
       1         3        5          8      10     15      20        30
Eclipse JDT Core - All Bugs - Predictive Power
           Spearman correlation                           NOCC All
0.67

                                  Metrics + SOC
0.61                                              Metrics + #Changes

0.55


0.49
                     Metrics LWSOC


0.42                                              Metrics + NOCC
                              Metrics EWSOC                Metrics
0.36

                                                                       n
0.30
       1         3        5          8      10     15      20        30
Eclipse JDT Core - All Bugs - Predictive Power
           Spearman correlation                           NOCC All
0.67

                                  Metrics + SOC
0.61                                              Metrics + #Changes
                                                   All CC measures
0.55


0.49
                     Metrics LWSOC


0.42                                              Metrics + NOCC
                              Metrics EWSOC                Metrics
0.36

                                                                       n
0.30
       1         3        5          8      10     15      20        30
Eclipse JDT Core - All Bugs - Predictive Power
           Spearman correlation                           NOCC All
0.67

                                  Metrics + SOC
0.61                                              Metrics + #Changes
                                                   All CC measures
0.55


0.49
                     Metrics LWSOC


0.42                                              Metrics + NOCC
                              Metrics EWSOC                Metrics
0.36

                                                                       n
0.30
       1         3        5          8      10     15      20        30
Eclipse JDT Core - All Bugs - Predictive Power
           Spearman correlation                      NOCC All
0.67

             Q2 Change coupli+ SOC
                           Metrics                  fect
                                   ng improves de#Changes
                                          Metrics +
                                  ues based All n source
                                             o
0.61
             prediction techniq                 CC measures
0.55         code metrics an  d #changes (slightly)
0.49
                     Metrics LWSOC


0.42                                          Metrics + NOCC
                              Metrics EWSOC           Metrics
0.36

                                                                 n
0.30
       1         3        5       8     10     15     20        30
Eclipse JDT Core - All Bugs - Predictive Power
           Spearman correlation                    NOCC All
0.67

             Q2 Change coupli+ SOC
                           Metrics                  fect
                                   ng improves de#Changes
                                          Metrics +
                                  ues based All n source
                                             o
0.61
             prediction techniq                 CC measures
0.55         code metrics an  d #changes (slightly)
                     Metrics LWSOC
0.49
             Q2* The overall results are worse for
0.42
             severe defects, but the improvement
                                          Metrics + NOCC
             over existingMetrics EWSOC is greaterMetrics
                           approaches
0.36

                                                              n
0.30
       1         3        5       8   10    15     20       30
Conclusion
Conclusion

   No study on change
  coupling and software
         defects
Conclusion

   No study on change
  coupling and software   Definitions of different
         defects           class-level change
                            coupling metrics
Conclusion

   No study on change
  coupling and software    Definitions of different
         defects            class-level change
                             coupling metrics

  Change coupling does
 correlate with software
         defects
Conclusion

   No study on change
  coupling and software     Definitions of different
         defects             class-level change
                              coupling metrics

  Change coupling does
 correlate with software    Change coupling can
         defects           improve existing defect
                            prediction techniques
Conclusion

   No study on change
  coupling and software         Definitions of different
         defects                 class-level change
                                  coupling metrics

  Change coupling does
 correlate with software       Change coupling can
         defects              improve existing defect
                               prediction techniques


              Change coupling is harmful!

More Related Content

Viewers also liked

Technology & Business Change - Retail Banking
Technology & Business Change - Retail BankingTechnology & Business Change - Retail Banking
Technology & Business Change - Retail BankingTom Maher
 
Mining Cause Effect Chains from Version Archives - ISSRE 2011
Mining Cause Effect Chains from Version Archives - ISSRE 2011Mining Cause Effect Chains from Version Archives - ISSRE 2011
Mining Cause Effect Chains from Version Archives - ISSRE 2011Kim Herzig
 
How Social Media Changes Business, Technology, and Society
How Social Media Changes Business, Technology, and SocietyHow Social Media Changes Business, Technology, and Society
How Social Media Changes Business, Technology, and SocietyKanda Runapongsa Saikaew
 
Technology and Change: It's good for business, is it good enough for education?
Technology and Change: It's good for business, is it good enough for education?Technology and Change: It's good for business, is it good enough for education?
Technology and Change: It's good for business, is it good enough for education?Hazel Owen
 
How technology change the business
How technology change the businessHow technology change the business
How technology change the businesss1180012
 
Business change
Business changeBusiness change
Business changeKim Parker
 
Content That Converts - Win Leads and Influence People
Content That Converts - Win Leads and Influence PeopleContent That Converts - Win Leads and Influence People
Content That Converts - Win Leads and Influence PeopleStrutta
 
Business and Technology Advice from the World's Top Executives
Business and Technology Advice from the World's Top ExecutivesBusiness and Technology Advice from the World's Top Executives
Business and Technology Advice from the World's Top ExecutivesVala Afshar
 
How technology and business is changing communication
How technology and business is changing communicationHow technology and business is changing communication
How technology and business is changing communicationHelge Tennø
 

Viewers also liked (11)

Technology & Business Change - Retail Banking
Technology & Business Change - Retail BankingTechnology & Business Change - Retail Banking
Technology & Business Change - Retail Banking
 
Mining Cause Effect Chains from Version Archives - ISSRE 2011
Mining Cause Effect Chains from Version Archives - ISSRE 2011Mining Cause Effect Chains from Version Archives - ISSRE 2011
Mining Cause Effect Chains from Version Archives - ISSRE 2011
 
Blog Posts HOPE
Blog Posts HOPEBlog Posts HOPE
Blog Posts HOPE
 
How Social Media Changes Business, Technology, and Society
How Social Media Changes Business, Technology, and SocietyHow Social Media Changes Business, Technology, and Society
How Social Media Changes Business, Technology, and Society
 
Technology and Change: It's good for business, is it good enough for education?
Technology and Change: It's good for business, is it good enough for education?Technology and Change: It's good for business, is it good enough for education?
Technology and Change: It's good for business, is it good enough for education?
 
How technology change the business
How technology change the businessHow technology change the business
How technology change the business
 
Business change
Business changeBusiness change
Business change
 
Managing Change for Technology Teams
Managing Change for Technology TeamsManaging Change for Technology Teams
Managing Change for Technology Teams
 
Content That Converts - Win Leads and Influence People
Content That Converts - Win Leads and Influence PeopleContent That Converts - Win Leads and Influence People
Content That Converts - Win Leads and Influence People
 
Business and Technology Advice from the World's Top Executives
Business and Technology Advice from the World's Top ExecutivesBusiness and Technology Advice from the World's Top Executives
Business and Technology Advice from the World's Top Executives
 
How technology and business is changing communication
How technology and business is changing communicationHow technology and business is changing communication
How technology and business is changing communication
 

Similar to On the Relationship Between Change Coupling and Software Defects

Monitoring service systems from
Monitoring service systems fromMonitoring service systems from
Monitoring service systems fromingenioustech
 
IMPLEMENTATION OF DYNAMIC COUPLING MEASUREMENT OF DISTRIBUTED OBJECT ORIENTED...
IMPLEMENTATION OF DYNAMIC COUPLING MEASUREMENT OF DISTRIBUTED OBJECT ORIENTED...IMPLEMENTATION OF DYNAMIC COUPLING MEASUREMENT OF DISTRIBUTED OBJECT ORIENTED...
IMPLEMENTATION OF DYNAMIC COUPLING MEASUREMENT OF DISTRIBUTED OBJECT ORIENTED...IJCSEA Journal
 
IMPLEMENTATION OF DYNAMIC COUPLING MEASUREMENT OF DISTRIBUTED OBJECT ORIENTED...
IMPLEMENTATION OF DYNAMIC COUPLING MEASUREMENT OF DISTRIBUTED OBJECT ORIENTED...IMPLEMENTATION OF DYNAMIC COUPLING MEASUREMENT OF DISTRIBUTED OBJECT ORIENTED...
IMPLEMENTATION OF DYNAMIC COUPLING MEASUREMENT OF DISTRIBUTED OBJECT ORIENTED...IJCSEA Journal
 
Coupling based structural metrics for measuring the quality of a software (sy...
Coupling based structural metrics for measuring the quality of a software (sy...Coupling based structural metrics for measuring the quality of a software (sy...
Coupling based structural metrics for measuring the quality of a software (sy...Mumbai Academisc
 
WIRELESS COMPUTING AND IT ECOSYSTEMS
WIRELESS COMPUTING AND IT ECOSYSTEMSWIRELESS COMPUTING AND IT ECOSYSTEMS
WIRELESS COMPUTING AND IT ECOSYSTEMScscpconf
 
Performancetestingbasedontimecomplexityanalysisforembeddedsoftware 1008150404...
Performancetestingbasedontimecomplexityanalysisforembeddedsoftware 1008150404...Performancetestingbasedontimecomplexityanalysisforembeddedsoftware 1008150404...
Performancetestingbasedontimecomplexityanalysisforembeddedsoftware 1008150404...NNfamily
 
Performance testing based on time complexity analysis for embedded software
Performance testing based on time complexity analysis for embedded softwarePerformance testing based on time complexity analysis for embedded software
Performance testing based on time complexity analysis for embedded softwareMr. Chanuwan
 
Software engineering Questions and Answers
Software engineering Questions and AnswersSoftware engineering Questions and Answers
Software engineering Questions and AnswersBala Ganesh
 
Survey paper
Survey paperSurvey paper
Survey paperIJASCSE
 
10.1.1.92.7063
10.1.1.92.706310.1.1.92.7063
10.1.1.92.7063bob lee
 
Inversion of Control
Inversion of ControlInversion of Control
Inversion of ControlGlen Alleman
 
System Structure for Dependable Software Systems
System Structure for Dependable Software SystemsSystem Structure for Dependable Software Systems
System Structure for Dependable Software SystemsVincenzo De Florio
 
Detecting the High Level Similarities in Software Implementation Process Usin...
Detecting the High Level Similarities in Software Implementation Process Usin...Detecting the High Level Similarities in Software Implementation Process Usin...
Detecting the High Level Similarities in Software Implementation Process Usin...IOSR Journals
 
Aspect Oriented Programming
Aspect Oriented ProgrammingAspect Oriented Programming
Aspect Oriented Programmingmukhtarhudaya
 
Finding Bad Code Smells with Neural Network Models
Finding Bad Code Smells with Neural Network Models Finding Bad Code Smells with Neural Network Models
Finding Bad Code Smells with Neural Network Models IJECEIAES
 
Giddings
GiddingsGiddings
Giddingsanesah
 
2012 ieee projects software engineering @ Seabirds ( Trichy, Chennai, Pondich...
2012 ieee projects software engineering @ Seabirds ( Trichy, Chennai, Pondich...2012 ieee projects software engineering @ Seabirds ( Trichy, Chennai, Pondich...
2012 ieee projects software engineering @ Seabirds ( Trichy, Chennai, Pondich...SBGC
 

Similar to On the Relationship Between Change Coupling and Software Defects (20)

Monitoring service systems from
Monitoring service systems fromMonitoring service systems from
Monitoring service systems from
 
IMPLEMENTATION OF DYNAMIC COUPLING MEASUREMENT OF DISTRIBUTED OBJECT ORIENTED...
IMPLEMENTATION OF DYNAMIC COUPLING MEASUREMENT OF DISTRIBUTED OBJECT ORIENTED...IMPLEMENTATION OF DYNAMIC COUPLING MEASUREMENT OF DISTRIBUTED OBJECT ORIENTED...
IMPLEMENTATION OF DYNAMIC COUPLING MEASUREMENT OF DISTRIBUTED OBJECT ORIENTED...
 
IMPLEMENTATION OF DYNAMIC COUPLING MEASUREMENT OF DISTRIBUTED OBJECT ORIENTED...
IMPLEMENTATION OF DYNAMIC COUPLING MEASUREMENT OF DISTRIBUTED OBJECT ORIENTED...IMPLEMENTATION OF DYNAMIC COUPLING MEASUREMENT OF DISTRIBUTED OBJECT ORIENTED...
IMPLEMENTATION OF DYNAMIC COUPLING MEASUREMENT OF DISTRIBUTED OBJECT ORIENTED...
 
Coupling based structural metrics for measuring the quality of a software (sy...
Coupling based structural metrics for measuring the quality of a software (sy...Coupling based structural metrics for measuring the quality of a software (sy...
Coupling based structural metrics for measuring the quality of a software (sy...
 
WIRELESS COMPUTING AND IT ECOSYSTEMS
WIRELESS COMPUTING AND IT ECOSYSTEMSWIRELESS COMPUTING AND IT ECOSYSTEMS
WIRELESS COMPUTING AND IT ECOSYSTEMS
 
Performancetestingbasedontimecomplexityanalysisforembeddedsoftware 1008150404...
Performancetestingbasedontimecomplexityanalysisforembeddedsoftware 1008150404...Performancetestingbasedontimecomplexityanalysisforembeddedsoftware 1008150404...
Performancetestingbasedontimecomplexityanalysisforembeddedsoftware 1008150404...
 
Performance testing based on time complexity analysis for embedded software
Performance testing based on time complexity analysis for embedded softwarePerformance testing based on time complexity analysis for embedded software
Performance testing based on time complexity analysis for embedded software
 
Software engineering Questions and Answers
Software engineering Questions and AnswersSoftware engineering Questions and Answers
Software engineering Questions and Answers
 
Survey paper
Survey paperSurvey paper
Survey paper
 
Security
SecuritySecurity
Security
 
10.1.1.92.7063
10.1.1.92.706310.1.1.92.7063
10.1.1.92.7063
 
Inversion of Control
Inversion of ControlInversion of Control
Inversion of Control
 
347 352
347 352347 352
347 352
 
java
javajava
java
 
System Structure for Dependable Software Systems
System Structure for Dependable Software SystemsSystem Structure for Dependable Software Systems
System Structure for Dependable Software Systems
 
Detecting the High Level Similarities in Software Implementation Process Usin...
Detecting the High Level Similarities in Software Implementation Process Usin...Detecting the High Level Similarities in Software Implementation Process Usin...
Detecting the High Level Similarities in Software Implementation Process Usin...
 
Aspect Oriented Programming
Aspect Oriented ProgrammingAspect Oriented Programming
Aspect Oriented Programming
 
Finding Bad Code Smells with Neural Network Models
Finding Bad Code Smells with Neural Network Models Finding Bad Code Smells with Neural Network Models
Finding Bad Code Smells with Neural Network Models
 
Giddings
GiddingsGiddings
Giddings
 
2012 ieee projects software engineering @ Seabirds ( Trichy, Chennai, Pondich...
2012 ieee projects software engineering @ Seabirds ( Trichy, Chennai, Pondich...2012 ieee projects software engineering @ Seabirds ( Trichy, Chennai, Pondich...
2012 ieee projects software engineering @ Seabirds ( Trichy, Chennai, Pondich...
 

Recently uploaded

Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Manik S Magar
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsSergiu Bodiu
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024Stephanie Beckett
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsMiki Katsuragi
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxhariprasad279825
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Mattias Andersson
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Scott Keck-Warren
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek SchlawackFwdays
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...Fwdays
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupFlorian Wilhelm
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfAlex Barbosa Coqueiro
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024Lonnie McRorey
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionDilum Bandara
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.Curtis Poe
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Commit University
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Enterprise Knowledge
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdfHyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdfPrecisely
 

Recently uploaded (20)

Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platforms
 
DMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special EditionDMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special Edition
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering Tips
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptx
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
 
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptxE-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project Setup
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdf
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An Introduction
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdfHyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
 

On the Relationship Between Change Coupling and Software Defects

  • 1. On the Relationship Between Change Coupling and Software Defects Marco D’Ambros Michele Lanza Romain Robbes REVEAL @ University of Lugano, CH
  • 2. Change Coupling t1 t2 t3 t4 t5 t6 c1 c2 Time Ball in Proceedings of the International Conference on Software Maintenance 1998 (ICSM ’98) Gall 1/10 199 Detection of Logical Coupling Based on Product Release History 199 7 8 Harald Gall, Karin Hajek, and Mehdi Jazayeri “The implicit relationship of Technical University of Vienna, Distributed Systems Group Argentinierstrasse 8/184-1, A-1040 Wien, Austria, Europe {gall,hajek,jazayeri}@infosys.tuwien.ac.at Requirements Abstract consists of 10 million lines of code (MLOC) per Code-based metrics such as coupling and cohesion are system release. Version used to measure a system’s structural complexity. But Software Control Implementation 2. Such measures do not reveal all dependencies (e.g. Process Technology dealing with large systems—those consisting of several History millions of lines— at the code level faces many prob- dynamic relations). In fact, some dependencies are lems. An alternative approach is to concentrate on the not written down either in documentation or in the system’s building blocks such as programs or modules code. The software engineer just “knows” that to Developers as the unit of examination. We present an approach that make a change of a certain type, he or she has to change a certain set of modules. two software artifacts that uses information in a release history of a system to un- cover logical dependencies and change patterns among We may say that such code-based measures reveal modules. We have developed the approach by working syntactic dependencies and what we are really interested with 20 releases of a large Telecommunications Switch- in is logical dependencies among modules. The purpose ing System. We use release information such as version of this paper is to present an approach to uncover such numbers of programs, modules, and subsystems together logical dependencies by analyzing the release history of a with change reports to discover common change behav- system. Release histories contain a wealth of information ior (i.e. change patterns) of modules. Our approach about the software structure. The task is just to analyze identifies logical coupling among modules in such a way them and uncover the information. that potential structural shortcomings can be identified In particular, we can analyze release histories to look and further examined, pointing to restructuring or for patterns of change: are there some modules that are reengineering opportunities. always changed together in a release? Are there sequen- tial dependencies such as if module A is changed in one 1 Introduction release, module B is changed in the next release? And so frequently change together” on. Large software systems are continuously modified and We have developed a technique called CAESAR for increase in size and complexity. After many enhance- detecting such patterns. We have applied the technique ments and other maintenance activities, modifications to a large system with a 20-release history and identified become hard to do. Therefore, methods and techniques potential dependencies among modules. To validate the are needed to restructure or even reengineer a system accuracy of these dependencies identified by our tech- into a more maintainable form. nique, we examined change reports that contain specific To evaluate the impact of changes, we need to under- change information for a release. The results have shown stand the relationships, that is, dependencies among that this approach is promising in identifying “logical” modules that compose the system. Current methods of couplings among modules across several releases. identifying dependencies are based on metrics such as Our technique reveals hidden dependencies not evi- coupling and cohesion measures [6,17]. These measures dent in the source code and identifies modules that are identify dependencies among modules by the existence of candidates for restructuring. The technique requires very such relationships as procedure calls or “include” direc- little data to be kept for each release of a system. Rather tives. There are two basic issues with these measures: than dealing with millions of lines of code, it works with structural information about programs, modules, and 1. These measures are based on source code which is subsystems, together with their version numbers and usually very large. In our case study the source code
  • 3. Previous research on Change Coupling Gall et. al., IWPSE ’03 Change coupling points to architectural weaknesses
  • 4. Previous research on Change Coupling Pinzger et. al., SoftVis ’05 Change coupling facilitates the detection of refactoring candidates
  • 5. Previous research on Change Coupling Beyer et. al., WCRE ’06 Change coupling helps the comprehension of system modularization
  • 6. Previous research on Change Coupling D’Ambros et. al., TSE ‘09 Change coupling helps in spotting misplaced software components
  • 7. Previous research on Change Coupling D’Ambros et. al., TSE ‘09 What about Changeare helps coupling softw misplaced in spotting defectsoftware components s?
  • 8. Previous research on Change Coupling D’Ambros et. al., TSE ‘09 What abonge ofowpcoupling helps Change ut in c t u aling ha s spottinge r misplaced Q 1 Does c defectft? are defects? sw so software components correlate with
  • 9. Previous research on Change Coupling D’Ambros et. al., TSE ‘09 What abonge ofowpcoupling helps Change ut in c t u aling ha s spottinge r misplaced Q 1 Does c defectft? are defects? sw so software components correlate with Q2 Does it improve existing defect prediction techniques?
  • 10. Change Coupling metrics Class #defects ? Foo 1 7 Bar 10 4 Boo 2 0
  • 11. Change Coupling metrics Class level change Class #defects ? coupling metrics Foo 1 7 Bar 10 4 Boo 2 0
  • 12. n-coupled classes t1 t2 t3 t4 t5 t6 c1 c2 c3 c4 c5 2 classes are n-coupled if they changed together at least n times
  • 13. n-coupled classes n=4 t1 t2 t3 t4 t5 t6 c1 c2 c3 c4 c5 2 classes are n-coupled if they changed together at least n times
  • 14. n-coupled classes n=4 t1 t2 t3 t4 t5 t6 c1 c2 c3 c4 c5 2 classes are n-coupled if they changed together at least n times
  • 15. n-coupled classes n=4 t1 t2 t3 t4 t5 t6 c1 c2 c3 c4 c5 2 classes are n-coupled if they changed together at least n times
  • 16. n-coupled classes n=5 t1 t2 t3 t4 t5 t6 c1 c2 c3 c4 c5 2 classes are n-coupled if they changed together at least n times
  • 17. NOCC(class, n): Number Of Coupled Classes NOCC(c2, 4) = 1 t1 t2 t3 t4 t5 t6 1 c1 c2 c3 c4 c5
  • 18. NOCC(class, n): Number Of Coupled Classes NOCC(c2, 4) = 1 + 1 t1 t2 t3 t4 t5 t6 1 c1 c2 c3 c4 1 c5
  • 19. SOC(class, n): Sum Of Coupling SOC(c2, 4) = t1 t2 t3 t4 t5 t6 c1 c2 c3 c4 c5
  • 20. SOC(class, n): Sum Of Coupling SOC(c2, 4) = 4 t1 t2 t3 t4 t5 t6 1 2 3 4 c1 c2 c3 c4 c5
  • 21. SOC(class, n): Sum Of Coupling SOC(c2, 4) = 4 + 5 t1 t2 t3 t4 t5 t6 c1 c2 c3 c4 c5 1 2 3 4 5
  • 22. Metrics with linear and exponential decay EWSOC: Exponentially Weighted Sum Of Coupling LWSOC: Linearly Weighted Sum Of Coupling k=5 k=4 k=3 k=2 k=1 t1 t2 t3 t4 t5 t6 c1 c2 Current release Time
  • 23. Metrics with linear and exponential decay EWSOC: Exponentially Weighted Sum Of Coupling LWSOC: Linearly Weighted Sum Of Coupling Exponential = 1 weight 24 Linear = 1 weight 5 k=5 k=4 k=3 k=2 k=1 t1 t2 t3 t4 t5 t6 c1 c2 Current release Time
  • 24. Metrics with linear and exponential decay EWSOC: Exponentially Weighted Sum Of Coupling LWSOC: Linearly Weighted Sum Of Coupling Exponential = 1 Exponential = 1 weight 20 weight 24 Linear = 1 Linear = 1 weight 1 weight 5 k=5 k=4 k=3 k=2 k=1 t1 t2 t3 t4 t5 t6 c1 c2 Current release Time
  • 25. Experiments Methodology Q1 Correlation analysis Q2 Regression analysis
  • 26. Experiments Methodology Q1 Correlation analysis Analyzed systems Q2 Regression analysis #classes #transactions ArgoUML 2,197 15,257 Eclipse JDT Core 1,193 13,186 Mylyn 3,050 9,373
  • 27. Experiments Methodology Q1 Correlation analysis Analyzed systems Q2 Regression analysis #classes #transactions ArgoUML 2,197 15,257 Eclipse JDT Core 1,193 13,186 Mylyn 3,050 9,373 Change coupling NOCC SOC EWSOC function LWSOC of n
  • 28. Experiments Methodology Q1 Correlation analysis Analyzed systems Q2 Regression analysis #classes #transactions ArgoUML 2,197 15,257 Eclipse JDT Core 1,193 13,186 Mylyn 3,050 9,373 Change coupling NOCC Baseline 6 CK metrics SOC + EWSOC 5 OO metrics function LWSOC of n + # changes
  • 29. Correlation analysis Q1 Does change coupling correlate w ith software defects?
  • 30. Correlation analysis Q1 Does change coupling correlate w ith software defects? Q1* Does it correlate more with severe software defects?
  • 31. Eclipse JDT Core - All bugs Spearman correlation n
  • 32. Eclipse JDT Core - All bugs Spearman correlation 0.9 0.8 0.7 0.6 0.5 0.4 n 0.3 1 3 5 8 10 15 20 30
  • 33. Eclipse JDT Core - All bugs Spearman correlation 0.9 0.8 0.7 0.6 0.5 Fan out 0.4 n 0.3 1 3 5 8 10 15 20 30
  • 34. Eclipse JDT Core - All bugs Spearman correlation 0.9 #Changes 0.8 0.7 0.6 0.5 Fan out 0.4 n 0.3 1 3 5 8 10 15 20 30
  • 35. Eclipse JDT Core - All bugs Spearman correlation 0.9 #Changes 0.8 SOC NOCC 0.7 LWSOC EWSOC 0.6 0.5 Fan out 0.4 n 0.3 1 3 5 8 10 15 20 30
  • 36. Eclipse JDT Core - All bugs Spearman correlation 0.9 #Changes 0.8 Q1 Chan ge coupling does 0.7 SOC correlate w ith software defects, NOCC LWSOCan all source code more th EWSOC 0.6 metrics, wor se than #changes 0.5 Fan out 0.4 n 0.3 1 3 5 8 10 15 20 30
  • 37. Eclipse JDT Core - All bugs Spearman correlation 0.9 #Changes 0.8 Q1 Chan ge coupling does 0.7 SOC correlate w ith software defects, NOCC LWSOCan all source code more th EWSOC 0.6 metrics, wor se than #changes 0.5 DecayFan outdels do not wor k mo 0.4 n 0.3 1 3 5 8 10 15 20 30
  • 38. Mylyn - Severe Bugs Spearman correlation n
  • 39. Mylyn - Severe Bugs Spearman correlation 0.40 0.37 0.33 0.30 0.27 0.23 n 0.20 1 3 5 8 10 15 20 30
  • 40. Mylyn - Severe Bugs Spearman correlation 0.40 0.37 0.33 LOC 0.30 0.27 0.23 n 0.20 1 3 5 8 10 15 20 30
  • 41. Mylyn - Severe Bugs Spearman correlation 0.40 #Changes 0.37 0.33 LOC 0.30 0.27 0.23 n 0.20 1 3 5 8 10 15 20 30
  • 42. Mylyn - Severe Bugs Spearman correlation 0.40 SOC #Changes 0.37 0.33 EWSOC NOCC LWSOC LOC 0.30 0.27 0.23 n 0.20 1 3 5 8 10 15 20 30
  • 43. Mylyn - Severe Bugs Spearman correlation 0.40 SOC #Changes 0.37 Q1* Cha nge c EWSOC ouplingNOCCrelates cor severe defects, but is LOC 0.33 less withLWSOC 0.30 bette r than all source code 0.27 m etrics and #changes 0.23 n 0.20 1 3 5 8 10 15 20 30
  • 44. Regression Analysis Q2 Does cha nge coupling improve defect pr ediction techniques?
  • 45. Regression Analysis Q2 Does cha nge coupling improve defect pr ediction techniques? Q2* Is the improvement greater for severe defects?
  • 46. Regression Models #changes NOCC(n) Source code metrics + SOC(n) EWSOC(n) LWSOC(n)
  • 47. Regression Models #changes NOCC all NOCC(n) (for all n) Source code metrics + SOC(n) EWSOC(n) LWSOC(n)
  • 48. Regression Models #changes NOCC all NOCC(n) (for all n) Source code metrics + SOC(n) EWSOC(n) All CC measures LWSOC(n) (for all n)
  • 49. Regression Models #changes NOCC all NOCC(n) (for all n) Source code metrics + SOC(n) EWSOC(n) All CC measures LWSOC(n) (for all n) W e measure explanative and predictive power of the models
  • 50. Eclipse JDT Core - Major Bugs - Explanative Power R² n
  • 51. Eclipse JDT Core - Major Bugs - Explanative Power R² 0.85 0.73 0.60 0.48 0.35 0.23 n 0.10 1 3 5 8 10 15 20 30
  • 52. Eclipse JDT Core - Major Bugs - Explanative Power R² 0.85 0.73 0.60 0.48 0.35 0.23 Metrics n 0.10 1 3 5 8 10 15 20 30
  • 53. Eclipse JDT Core - Major Bugs - Explanative Power R² 0.85 Metrics + #Changes 0.73 0.60 0.48 0.35 0.23 Metrics n 0.10 1 3 5 8 10 15 20 30
  • 54. Eclipse JDT Core - Major Bugs - Explanative Power R² 0.85 Metrics + #Changes 0.73 Metrics + SOC 0.60 0.48 Metrics LWSOC Metrics + NOCC 0.35 Metrics EWSOC 0.23 Metrics n 0.10 1 3 5 8 10 15 20 30
  • 55. Eclipse JDT Core - Major Bugs - Explanative Power R² 0.85 Metrics + #Changes NOCC All 0.73 Metrics + SOC 0.60 0.48 Metrics LWSOC Metrics + NOCC 0.35 Metrics EWSOC 0.23 Metrics n 0.10 1 3 5 8 10 15 20 30
  • 56. Eclipse JDT Core - Major Bugs - Explanative Power R² All CC measures 0.85 Metrics + #Changes NOCC All 0.73 Metrics + SOC 0.60 0.48 Metrics LWSOC Metrics + NOCC 0.35 Metrics EWSOC 0.23 Metrics n 0.10 1 3 5 8 10 15 20 30
  • 57. Eclipse JDT Core - All Bugs - Predictive Power Spearman correlation n
  • 58. Eclipse JDT Core - All Bugs - Predictive Power Spearman correlation 0.67 0.61 0.55 0.49 0.42 0.36 n 0.30 1 3 5 8 10 15 20 30
  • 59. Eclipse JDT Core - All Bugs - Predictive Power Spearman correlation 0.67 0.61 0.55 0.49 0.42 Metrics 0.36 n 0.30 1 3 5 8 10 15 20 30
  • 60. Eclipse JDT Core - All Bugs - Predictive Power Spearman correlation 0.67 0.61 Metrics + #Changes 0.55 0.49 0.42 Metrics 0.36 n 0.30 1 3 5 8 10 15 20 30
  • 61. Eclipse JDT Core - All Bugs - Predictive Power Spearman correlation 0.67 Metrics + SOC 0.61 Metrics + #Changes 0.55 0.49 Metrics LWSOC 0.42 Metrics + NOCC Metrics EWSOC Metrics 0.36 n 0.30 1 3 5 8 10 15 20 30
  • 62. Eclipse JDT Core - All Bugs - Predictive Power Spearman correlation NOCC All 0.67 Metrics + SOC 0.61 Metrics + #Changes 0.55 0.49 Metrics LWSOC 0.42 Metrics + NOCC Metrics EWSOC Metrics 0.36 n 0.30 1 3 5 8 10 15 20 30
  • 63. Eclipse JDT Core - All Bugs - Predictive Power Spearman correlation NOCC All 0.67 Metrics + SOC 0.61 Metrics + #Changes All CC measures 0.55 0.49 Metrics LWSOC 0.42 Metrics + NOCC Metrics EWSOC Metrics 0.36 n 0.30 1 3 5 8 10 15 20 30
  • 64. Eclipse JDT Core - All Bugs - Predictive Power Spearman correlation NOCC All 0.67 Metrics + SOC 0.61 Metrics + #Changes All CC measures 0.55 0.49 Metrics LWSOC 0.42 Metrics + NOCC Metrics EWSOC Metrics 0.36 n 0.30 1 3 5 8 10 15 20 30
  • 65. Eclipse JDT Core - All Bugs - Predictive Power Spearman correlation NOCC All 0.67 Q2 Change coupli+ SOC Metrics fect ng improves de#Changes Metrics + ues based All n source o 0.61 prediction techniq CC measures 0.55 code metrics an d #changes (slightly) 0.49 Metrics LWSOC 0.42 Metrics + NOCC Metrics EWSOC Metrics 0.36 n 0.30 1 3 5 8 10 15 20 30
  • 66. Eclipse JDT Core - All Bugs - Predictive Power Spearman correlation NOCC All 0.67 Q2 Change coupli+ SOC Metrics fect ng improves de#Changes Metrics + ues based All n source o 0.61 prediction techniq CC measures 0.55 code metrics an d #changes (slightly) Metrics LWSOC 0.49 Q2* The overall results are worse for 0.42 severe defects, but the improvement Metrics + NOCC over existingMetrics EWSOC is greaterMetrics approaches 0.36 n 0.30 1 3 5 8 10 15 20 30
  • 68. Conclusion No study on change coupling and software defects
  • 69. Conclusion No study on change coupling and software Definitions of different defects class-level change coupling metrics
  • 70. Conclusion No study on change coupling and software Definitions of different defects class-level change coupling metrics Change coupling does correlate with software defects
  • 71. Conclusion No study on change coupling and software Definitions of different defects class-level change coupling metrics Change coupling does correlate with software Change coupling can defects improve existing defect prediction techniques
  • 72. Conclusion No study on change coupling and software Definitions of different defects class-level change coupling metrics Change coupling does correlate with software Change coupling can defects improve existing defect prediction techniques Change coupling is harmful!