SlideShare a Scribd company logo
1 of 30
Download to read offline
How does context affect the
distribution of software
maintainability metrics?
Feng Zhang, Audris Mockus, Ying Zou, Foutse Khomh,
and Ahmed E. Hassan
2
Software Metrics
Numerous Software
3
Various Usage of Software Metrics
4
Contexts !
Motivation
5
In Software Engineering Area?
6
What are the Contexts of Software?
Age
(AG)
Number of Changes
(NC)
Life Span
(LS)
Number of Downloads
(ND)
Application Domain
(AD)
Programming Language
(PL)
7
39 Software Maintainability Metrics
Complexity (14 metrics) Abstraction (5 metrics)
Coupling (8 metrics)
Cohesion (4 metrics)
Encapsulation (4 metrics)
Documentation (4 metrics)
8
Data Collection
56,833
824
9
Data Cleaning
618
506
478
390
320
824
10
31
26
23
29
49
19
16
41
29
14
13
7
7
9
7
Build Tools
Code Generators
Communications
Framework
Games / Entertainmaint
Internet
Network
Software Development
System Administrator
Build & CodeGen
Comm & Internet
Comm & Network
Games & Internet
Internet & SW Dev
SW Dev & Sys Admin
57
85
18
146
14
C
C++
C#
Java
Pascal
Data Description
320
Software
Systems
11
Research Questions
12
Separately
RQ1. Analysis Methods
13
RQ1. Analysis Methods (cont’)
For example
C Java PascalC++ C#
Metric
1
Metric
1
Metric
1
Metric
1
Metric
1
Metric
n
Metric
n
Metric
n
Metric
n
Metric
n
KruskalWallis test
KruskalWallis test
14
Complexity (8/14 metrics) Abstraction (1/5 metrics)
Coupling (5/8 metrics)
Cohesion (2/4 metrics)
Encapsulation (1/4 metrics)
Documentation (3/4 metrics)
YES!! the Contexts Matter!
51 % of metrics are
impacted by all Six
Contexts
15
and Among the Six Contexts …
at least 72 % of
metrics are impacted
by a Single Context
16
Does it mean ALL six contexts
should be considered all the time?
17
Research Question 2
18
RQ2. Analysis Methods
19
RQ2. Analysis Methods (cont’)
C Java PascalC++ C#
Metric
i
Metric
i Mann-Whitney U test
Metric
i
Metric
i Mann-Whitney U test
Metric
i
Metric
i Mann-Whitney U test
Metric
i
Metric
i Mann-Whitney U test
Metric
i
Metric
i Mann-Whitney U test
Metric
i Mann-Whitney U test
Metric
i
20
RQ2. Analysis Methods (cont’)
0.147 0.330 0.474Cliff’s delta
14.7% 33.0% 47.4%% of non-overlap
Small Medium LargeCohen’s standard
0.20 0.50 0.80Cohen’s d
21
RQ2. Findings for
each Category of Metrics
22
Metric AD PL AG LS NC ND
TLOC - - - -  -
TNF - - - -  -
TNC   - -  -
TNM   - -  -
TNS - - - - - -
CLOC - - - - - -
NOM - - - - - -
NIM - - - - - -
NIV - - - - - -
WMC - - - - - -
NMP - - - - - -
CC - - - - - -
NPATH - - - - - -
MNL - - - - - -
Contexts Impacting ‘Complexity’
AD: Application Domain
PL : Programming Language
NC: Number of Changes
23
Metric AD PL AG LS NC ND
CF - - - -  -
CBO   - - - -
ICP - - - - - -
MPC - - - - - -
RFC   - - - -
NMI -  - - - -
FANIN - - - - - -
FANOUT - - - - - -
Contexts Impacting ‘Coupling’
AD: Application Domain
PL : Programming Language
NC: Number of Changes
24
Metric AD PL AG LS NC ND
LCOM  - - - - -
TCC - - - - - -
LCC - - - - - -
ICH - - - - - -
Contexts Impacting ‘Cohesion’
AD: Application Domain
25
Metric AD PL AG LS NC ND
NACI -  - - - -
MIF -  - - - -
IFANIN   - - - -
NOC - - - - - -
DIT  - - - - -
Contexts Impacting ‘Abstraction’
AD: Application Domain
PL : Programming Language
26
Metric AD PL AG LS NC ND
RPA  - - - - -
RPM - - - - - -
RSA - - - - - -
RSM  - - - - -
Contexts Impacting ‘Encapsulation’
AD: Application Domain
27
Metric AD PL AG LS NC ND
CLC - - - - - -
RCCC   - - - -
CLM - - - - - -
RCCM - - - - - -
Contexts Impacting ‘Documentation’
AD: Application Domain
PL : Programming Language
28
Summary of RQ2 Findings
Metric Category AD PL AG LS NC ND
Complexity   - -  -
Coupling   - -  -
Cohesion  - - - - -
Abstraction   - - - -
Encapsulation  - - - - -
Documentation   - - - -
AD: Application Domain
PL : Programming Language
NC: Number of Changes
29
Metric Category Context Groups
Complexity
AD (2) (Framework); and others
PL (3) (C); (Pascal); and others
NC (3) (Low NC;) (moderate NC); and (high NC)
Coupling
AD (3) (Communication, Network); (Build Tools, Code
Generators;) and others
PL (3) (Pascal;) (Java;) and others
NC (3) (Low NC); (moderate NC); and (high NC)
Cohesion AD (2) (Communication, Network); and others
Abstraction
AD (4) (Communication, Network); (Games); (Build Tools,
Code Generators); and others
PL (3) (Java;) (C++); and others
Encapsulation AD (3) (BuildTools); (Communication, Network); and others
Documentation
AD (2) (BuildTools, Code Generators); and others
PL (2) (Java); and others
Guidelines for Benchmarking
Maintainability Metrics
30

More Related Content

Similar to Icsm2013 contexts (1)

Sandeep Kumar Yarlagadda_Professional Resume
Sandeep Kumar Yarlagadda_Professional ResumeSandeep Kumar Yarlagadda_Professional Resume
Sandeep Kumar Yarlagadda_Professional Resume
sandeep kumar yarlagadda
 

Similar to Icsm2013 contexts (1) (20)

Introduction to IBM Shared Memory Communications Version 2 (SMCv2) and SMC-Dv2
Introduction to IBM Shared Memory Communications Version 2 (SMCv2) and SMC-Dv2Introduction to IBM Shared Memory Communications Version 2 (SMCv2) and SMC-Dv2
Introduction to IBM Shared Memory Communications Version 2 (SMCv2) and SMC-Dv2
 
3 gpp lte-pdcp
3 gpp lte-pdcp3 gpp lte-pdcp
3 gpp lte-pdcp
 
Cadence Design Flow.pptx
Cadence Design Flow.pptxCadence Design Flow.pptx
Cadence Design Flow.pptx
 
CS-Core Mobile Network (General)
CS-Core Mobile Network (General)CS-Core Mobile Network (General)
CS-Core Mobile Network (General)
 
LTE-Network-Planning-Huawei-Technologies EMERSON EDUARDO RODRIGUES
LTE-Network-Planning-Huawei-Technologies EMERSON EDUARDO RODRIGUESLTE-Network-Planning-Huawei-Technologies EMERSON EDUARDO RODRIGUES
LTE-Network-Planning-Huawei-Technologies EMERSON EDUARDO RODRIGUES
 
3rd 3DDRESD: Rebit
3rd 3DDRESD: Rebit3rd 3DDRESD: Rebit
3rd 3DDRESD: Rebit
 
HIS 2017 Mark Batty-Industrial concurrency specification for C/C++
HIS 2017 Mark Batty-Industrial concurrency specification for C/C++HIS 2017 Mark Batty-Industrial concurrency specification for C/C++
HIS 2017 Mark Batty-Industrial concurrency specification for C/C++
 
Santhosh Resume
Santhosh ResumeSanthosh Resume
Santhosh Resume
 
Design and implementation of DADCT
Design and implementation of DADCTDesign and implementation of DADCT
Design and implementation of DADCT
 
computer architecture.
computer architecture.computer architecture.
computer architecture.
 
Software Defined RAN
Software Defined RANSoftware Defined RAN
Software Defined RAN
 
CDR2(Sajjad Tarahomi)
CDR2(Sajjad Tarahomi)CDR2(Sajjad Tarahomi)
CDR2(Sajjad Tarahomi)
 
Sandeep Kumar Yarlagadda_Professional Resume
Sandeep Kumar Yarlagadda_Professional ResumeSandeep Kumar Yarlagadda_Professional Resume
Sandeep Kumar Yarlagadda_Professional Resume
 
Early-stage topological and technological choices for TSN-based communication...
Early-stage topological and technological choices for TSN-based communication...Early-stage topological and technological choices for TSN-based communication...
Early-stage topological and technological choices for TSN-based communication...
 
SMART Seminar Series: "OneM2M – Towards end-to-end interoperability of the IoT"
SMART Seminar Series: "OneM2M – Towards end-to-end interoperability of the IoT"SMART Seminar Series: "OneM2M – Towards end-to-end interoperability of the IoT"
SMART Seminar Series: "OneM2M – Towards end-to-end interoperability of the IoT"
 
Dpdk applications
Dpdk applicationsDpdk applications
Dpdk applications
 
Computer_Architecture_3rd_Edition_by_Moris_Mano_Ch_07.ppt
Computer_Architecture_3rd_Edition_by_Moris_Mano_Ch_07.pptComputer_Architecture_3rd_Edition_by_Moris_Mano_Ch_07.ppt
Computer_Architecture_3rd_Edition_by_Moris_Mano_Ch_07.ppt
 
Microprogrammed of organisation and architecture of computer.pptx
Microprogrammed of organisation and architecture of computer.pptxMicroprogrammed of organisation and architecture of computer.pptx
Microprogrammed of organisation and architecture of computer.pptx
 
COA 2.1 Microprogrammed control systems of btech 2nd year students.pptx
COA 2.1 Microprogrammed control systems of btech 2nd year students.pptxCOA 2.1 Microprogrammed control systems of btech 2nd year students.pptx
COA 2.1 Microprogrammed control systems of btech 2nd year students.pptx
 
Auto conversion of serial C code to CUDA code
Auto conversion of serial C code to CUDA codeAuto conversion of serial C code to CUDA code
Auto conversion of serial C code to CUDA code
 

More from SAIL_QU

Studying the Integration Practices and the Evolution of Ad Libraries in the G...
Studying the Integration Practices and the Evolution of Ad Libraries in the G...Studying the Integration Practices and the Evolution of Ad Libraries in the G...
Studying the Integration Practices and the Evolution of Ad Libraries in the G...
SAIL_QU
 
Studying User-Developer Interactions Through the Distribution and Reviewing M...
Studying User-Developer Interactions Through the Distribution and Reviewing M...Studying User-Developer Interactions Through the Distribution and Reviewing M...
Studying User-Developer Interactions Through the Distribution and Reviewing M...
SAIL_QU
 
Studying online distribution platforms for games through the mining of data f...
Studying online distribution platforms for games through the mining of data f...Studying online distribution platforms for games through the mining of data f...
Studying online distribution platforms for games through the mining of data f...
SAIL_QU
 
Understanding the Factors for Fast Answers in Technical Q&A Websites: An Empi...
Understanding the Factors for Fast Answers in Technical Q&A Websites: An Empi...Understanding the Factors for Fast Answers in Technical Q&A Websites: An Empi...
Understanding the Factors for Fast Answers in Technical Q&A Websites: An Empi...
SAIL_QU
 
Investigating the Challenges in Selenium Usage and Improving the Testing Effi...
Investigating the Challenges in Selenium Usage and Improving the Testing Effi...Investigating the Challenges in Selenium Usage and Improving the Testing Effi...
Investigating the Challenges in Selenium Usage and Improving the Testing Effi...
SAIL_QU
 
Mining Development Knowledge to Understand and Support Software Logging Pract...
Mining Development Knowledge to Understand and Support Software Logging Pract...Mining Development Knowledge to Understand and Support Software Logging Pract...
Mining Development Knowledge to Understand and Support Software Logging Pract...
SAIL_QU
 

More from SAIL_QU (20)

Studying the Integration Practices and the Evolution of Ad Libraries in the G...
Studying the Integration Practices and the Evolution of Ad Libraries in the G...Studying the Integration Practices and the Evolution of Ad Libraries in the G...
Studying the Integration Practices and the Evolution of Ad Libraries in the G...
 
Studying the Dialogue Between Users and Developers of Free Apps in the Google...
Studying the Dialogue Between Users and Developers of Free Apps in the Google...Studying the Dialogue Between Users and Developers of Free Apps in the Google...
Studying the Dialogue Between Users and Developers of Free Apps in the Google...
 
Improving the testing efficiency of selenium-based load tests
Improving the testing efficiency of selenium-based load testsImproving the testing efficiency of selenium-based load tests
Improving the testing efficiency of selenium-based load tests
 
Studying User-Developer Interactions Through the Distribution and Reviewing M...
Studying User-Developer Interactions Through the Distribution and Reviewing M...Studying User-Developer Interactions Through the Distribution and Reviewing M...
Studying User-Developer Interactions Through the Distribution and Reviewing M...
 
Studying online distribution platforms for games through the mining of data f...
Studying online distribution platforms for games through the mining of data f...Studying online distribution platforms for games through the mining of data f...
Studying online distribution platforms for games through the mining of data f...
 
Understanding the Factors for Fast Answers in Technical Q&A Websites: An Empi...
Understanding the Factors for Fast Answers in Technical Q&A Websites: An Empi...Understanding the Factors for Fast Answers in Technical Q&A Websites: An Empi...
Understanding the Factors for Fast Answers in Technical Q&A Websites: An Empi...
 
Investigating the Challenges in Selenium Usage and Improving the Testing Effi...
Investigating the Challenges in Selenium Usage and Improving the Testing Effi...Investigating the Challenges in Selenium Usage and Improving the Testing Effi...
Investigating the Challenges in Selenium Usage and Improving the Testing Effi...
 
Mining Development Knowledge to Understand and Support Software Logging Pract...
Mining Development Knowledge to Understand and Support Software Logging Pract...Mining Development Knowledge to Understand and Support Software Logging Pract...
Mining Development Knowledge to Understand and Support Software Logging Pract...
 
Which Log Level Should Developers Choose For a New Logging Statement?
Which Log Level Should Developers Choose For a New Logging Statement?Which Log Level Should Developers Choose For a New Logging Statement?
Which Log Level Should Developers Choose For a New Logging Statement?
 
Towards Just-in-Time Suggestions for Log Changes
Towards Just-in-Time Suggestions for Log ChangesTowards Just-in-Time Suggestions for Log Changes
Towards Just-in-Time Suggestions for Log Changes
 
The Impact of Task Granularity on Co-evolution Analyses
The Impact of Task Granularity on Co-evolution AnalysesThe Impact of Task Granularity on Co-evolution Analyses
The Impact of Task Granularity on Co-evolution Analyses
 
A Framework for Evaluating the Results of the SZZ Approach for Identifying Bu...
A Framework for Evaluating the Results of the SZZ Approach for Identifying Bu...A Framework for Evaluating the Results of the SZZ Approach for Identifying Bu...
A Framework for Evaluating the Results of the SZZ Approach for Identifying Bu...
 
How are Discussions Associated with Bug Reworking? An Empirical Study on Open...
How are Discussions Associated with Bug Reworking? An Empirical Study on Open...How are Discussions Associated with Bug Reworking? An Empirical Study on Open...
How are Discussions Associated with Bug Reworking? An Empirical Study on Open...
 
A Study of the Relation of Mobile Device Attributes with the User-Perceived Q...
A Study of the Relation of Mobile Device Attributes with the User-Perceived Q...A Study of the Relation of Mobile Device Attributes with the User-Perceived Q...
A Study of the Relation of Mobile Device Attributes with the User-Perceived Q...
 
A Large-Scale Study of the Impact of Feature Selection Techniques on Defect C...
A Large-Scale Study of the Impact of Feature Selection Techniques on Defect C...A Large-Scale Study of the Impact of Feature Selection Techniques on Defect C...
A Large-Scale Study of the Impact of Feature Selection Techniques on Defect C...
 
Studying the Dialogue Between Users and Developers of Free Apps in the Google...
Studying the Dialogue Between Users and Developers of Free Apps in the Google...Studying the Dialogue Between Users and Developers of Free Apps in the Google...
Studying the Dialogue Between Users and Developers of Free Apps in the Google...
 
What Do Programmers Know about Software Energy Consumption?
What Do Programmers Know about Software Energy Consumption?What Do Programmers Know about Software Energy Consumption?
What Do Programmers Know about Software Energy Consumption?
 
Threshold for Size and Complexity Metrics: A Case Study from the Perspective ...
Threshold for Size and Complexity Metrics: A Case Study from the Perspective ...Threshold for Size and Complexity Metrics: A Case Study from the Perspective ...
Threshold for Size and Complexity Metrics: A Case Study from the Perspective ...
 
Revisiting the Experimental Design Choices for Approaches for the Automated R...
Revisiting the Experimental Design Choices for Approaches for the Automated R...Revisiting the Experimental Design Choices for Approaches for the Automated R...
Revisiting the Experimental Design Choices for Approaches for the Automated R...
 
Measuring Program Comprehension: A Large-Scale Field Study with Professionals
Measuring Program Comprehension: A Large-Scale Field Study with ProfessionalsMeasuring Program Comprehension: A Large-Scale Field Study with Professionals
Measuring Program Comprehension: A Large-Scale Field Study with Professionals
 

Icsm2013 contexts (1)

  • 1. How does context affect the distribution of software maintainability metrics? Feng Zhang, Audris Mockus, Ying Zou, Foutse Khomh, and Ahmed E. Hassan
  • 3. 3 Various Usage of Software Metrics
  • 6. 6 What are the Contexts of Software? Age (AG) Number of Changes (NC) Life Span (LS) Number of Downloads (ND) Application Domain (AD) Programming Language (PL)
  • 7. 7 39 Software Maintainability Metrics Complexity (14 metrics) Abstraction (5 metrics) Coupling (8 metrics) Cohesion (4 metrics) Encapsulation (4 metrics) Documentation (4 metrics)
  • 10. 10 31 26 23 29 49 19 16 41 29 14 13 7 7 9 7 Build Tools Code Generators Communications Framework Games / Entertainmaint Internet Network Software Development System Administrator Build & CodeGen Comm & Internet Comm & Network Games & Internet Internet & SW Dev SW Dev & Sys Admin 57 85 18 146 14 C C++ C# Java Pascal Data Description 320 Software Systems
  • 13. 13 RQ1. Analysis Methods (cont’) For example C Java PascalC++ C# Metric 1 Metric 1 Metric 1 Metric 1 Metric 1 Metric n Metric n Metric n Metric n Metric n KruskalWallis test KruskalWallis test
  • 14. 14 Complexity (8/14 metrics) Abstraction (1/5 metrics) Coupling (5/8 metrics) Cohesion (2/4 metrics) Encapsulation (1/4 metrics) Documentation (3/4 metrics) YES!! the Contexts Matter! 51 % of metrics are impacted by all Six Contexts
  • 15. 15 and Among the Six Contexts … at least 72 % of metrics are impacted by a Single Context
  • 16. 16 Does it mean ALL six contexts should be considered all the time?
  • 19. 19 RQ2. Analysis Methods (cont’) C Java PascalC++ C# Metric i Metric i Mann-Whitney U test Metric i Metric i Mann-Whitney U test Metric i Metric i Mann-Whitney U test Metric i Metric i Mann-Whitney U test Metric i Metric i Mann-Whitney U test Metric i Mann-Whitney U test Metric i
  • 20. 20 RQ2. Analysis Methods (cont’) 0.147 0.330 0.474Cliff’s delta 14.7% 33.0% 47.4%% of non-overlap Small Medium LargeCohen’s standard 0.20 0.50 0.80Cohen’s d
  • 21. 21 RQ2. Findings for each Category of Metrics
  • 22. 22 Metric AD PL AG LS NC ND TLOC - - - -  - TNF - - - -  - TNC   - -  - TNM   - -  - TNS - - - - - - CLOC - - - - - - NOM - - - - - - NIM - - - - - - NIV - - - - - - WMC - - - - - - NMP - - - - - - CC - - - - - - NPATH - - - - - - MNL - - - - - - Contexts Impacting ‘Complexity’ AD: Application Domain PL : Programming Language NC: Number of Changes
  • 23. 23 Metric AD PL AG LS NC ND CF - - - -  - CBO   - - - - ICP - - - - - - MPC - - - - - - RFC   - - - - NMI -  - - - - FANIN - - - - - - FANOUT - - - - - - Contexts Impacting ‘Coupling’ AD: Application Domain PL : Programming Language NC: Number of Changes
  • 24. 24 Metric AD PL AG LS NC ND LCOM  - - - - - TCC - - - - - - LCC - - - - - - ICH - - - - - - Contexts Impacting ‘Cohesion’ AD: Application Domain
  • 25. 25 Metric AD PL AG LS NC ND NACI -  - - - - MIF -  - - - - IFANIN   - - - - NOC - - - - - - DIT  - - - - - Contexts Impacting ‘Abstraction’ AD: Application Domain PL : Programming Language
  • 26. 26 Metric AD PL AG LS NC ND RPA  - - - - - RPM - - - - - - RSA - - - - - - RSM  - - - - - Contexts Impacting ‘Encapsulation’ AD: Application Domain
  • 27. 27 Metric AD PL AG LS NC ND CLC - - - - - - RCCC   - - - - CLM - - - - - - RCCM - - - - - - Contexts Impacting ‘Documentation’ AD: Application Domain PL : Programming Language
  • 28. 28 Summary of RQ2 Findings Metric Category AD PL AG LS NC ND Complexity   - -  - Coupling   - -  - Cohesion  - - - - - Abstraction   - - - - Encapsulation  - - - - - Documentation   - - - - AD: Application Domain PL : Programming Language NC: Number of Changes
  • 29. 29 Metric Category Context Groups Complexity AD (2) (Framework); and others PL (3) (C); (Pascal); and others NC (3) (Low NC;) (moderate NC); and (high NC) Coupling AD (3) (Communication, Network); (Build Tools, Code Generators;) and others PL (3) (Pascal;) (Java;) and others NC (3) (Low NC); (moderate NC); and (high NC) Cohesion AD (2) (Communication, Network); and others Abstraction AD (4) (Communication, Network); (Games); (Build Tools, Code Generators); and others PL (3) (Java;) (C++); and others Encapsulation AD (3) (BuildTools); (Communication, Network); and others Documentation AD (2) (BuildTools, Code Generators); and others PL (2) (Java); and others Guidelines for Benchmarking Maintainability Metrics
  • 30. 30