SlideShare ist ein Scribd-Unternehmen logo
1 von 121
Software Measurement Software Economics 2010
Anton Litvinenko ,[object Object]
Key competence:  software measurement and metrics ,[object Object]
MSc in computer science at Tartu University
Agenda ,[object Object]
Are software metrics “ good ” or “ bad ”?
What is a “ measure ”?
What is a “measure”? “ Way of associating a  number  with some  attribute of a physical object ” height -> meters temperature -> degrees Celsius
What is “measure”? One-to-one mapping  between  physical  objects and  formal  objects (e.g numbers)
Same Stuff Formally ,[object Object]
Relations on these objects ( e.g. more, equal )
Binary operations on these objects ( e.g. combine, put together ) ,[object Object]
Relationships and Operations ,[object Object]
Steve Ballmer has 4 apples ,[object Object]
Jobs and Ballmer can cooperate and put their apples together to have a larger pile
We defined a “ complete transition ” from “ real world ” into “ formal world ”
Same Stuff Formally... again ,[object Object]
B be a relational system of  formal objects  ( e.g.  numbers)
m be a measure from A to B then
Tuple  A ,  B  and  m  is a  scale  if ,[object Object]
For each operator in A there is a corresponding operator in B
Why is this important?
What Can You Say?
Why is this important? ,[object Object]
20 modules with complexity 10 – 30 range ,[object Object]
We don't have intuition for such cases
Intelligence Barrier
Example: Temperature ,[object Object]
Anton : today is 4ºC, yesterday was 27ºC ,[object Object],[object Object]
Anton :  Yesterday was warmer than today
Example: Temperature ,[object Object]
Anton : today is 4ºC, yesterday was 27ºC ,[object Object],[object Object],[object Object]
Statement is  meaningful  when it gives  same result  on  all similar  scales
Scales  are  similar  when there is a  transformation  from one scale to another that  retains all defined relations and operations
Nominal Scale ,[object Object],[object Object]
View from 3000 feet :) Nominal Scales Gender T-shirt Numbering
Ordinal Scale ,[object Object]
Middle element –  median ,[object Object]
All Ordinal Scales Are Nominal Nominal Ordinal Gender T-shirt Numbering Top 100 Grading
Interval Scale ,[object Object]
Similar – reachable via  positive linear transformation :  t(x) = ax + b ,[object Object]
Interval Scales Are Ordinal Nominal Ordinal Interval Gender T-shirt Numbering Top 100 Grading Temperature
Ratio Scale ,[object Object]
Similar – reachable via positive linear transformation in form of  t(x) = ax ,[object Object],[object Object]
Ratio Scales Are Interval Nominal Ordinal Interval Ratio Gender T-shirt Numbering Top 100 Grading Temperature Length Height
Absolute Scale ,[object Object],[object Object]
My software is 25 lines of code
Absolute Scales Are Ratio Nominal Ordinal Interval Ratio Absolute Scales Gender T-shirt Numbering Top 100 Grading Temperature Length Height Team Size
Exercise 2 ,[object Object]
Quality  is only  ordinal  (rarely interval)
Judgment in terms of value ,[object Object]
Should we pay 2x for 2x quality?  ,[object Object]
In This Course:  Metric = Measure
Software Metric  is a  measure  of anything directly related to  software  or its  production
Agenda ,[object Object]
Examples of software metrics ,[object Object]
Can anybody name any software metric?
Lines Of Code (LOC) – Product Size ,[object Object],[object Object],[object Object]
Lines Of Code
Lines Of Code – Summary ,[object Object],[object Object]
Comments
Several statements on one line ,[object Object]
Doesn't respect complexity and content
McCabe's Cyclomatic Complexity ,[object Object]
Complexity of a program ,[object Object]
Usually calculated using flow graph ,[object Object],[object Object]
McCabe's Cyclomatic Complexity
McCabe's Cyclomatic Complexity ,[object Object]
n = 6
p = 1
V(G) = 3
Cyclomatic Complexity – Summary ,[object Object]
Maintainability ,[object Object],[object Object],[object Object],[object Object],[object Object]
Exercise 3 ,[object Object]
Draw a  flow graph
Calculate  McCabe's cyclomatic complexity Code snippet
Agenda ,[object Object]
Examples of software metrics ,[object Object]
Object oriented metrics
Object Oriented Metrics ,[object Object],[object Object]
Measure unique aspects of the  object oriented  approach
Inheritance Metrics ,[object Object],NOC: 2 DIT: 2 NOC: 3 DIT: 1
Complexity ,[object Object]
Complexity – Example RFC = 6, WMC = 1 + 2 + 1 = 4
Coupling ,[object Object]
Coupling – Example CBO = 2, LCOM = 3 – 0 = 3
Coupling – Example LCOM = 2 – 1 = 1
Agenda ,[object Object]
Examples of software metrics ,[object Object]
Object oriented metrics
Object oriented design quality metrics
Object Oriented Design ,[object Object]
OO Design Quality Metrics ,[object Object]
Measure  quality  of an  object oriented design
Can we divide dependencies into “ good ” and “ bad ”? Dependencies Between Classes
Dependencies ,[object Object]
Stable ,[object Object]
Hard to change = many dependents = responsible ,[object Object],[object Object]
Easy to change = no dependents = irresponsible
Class Category ,[object Object]
Reused together
Same goal ,[object Object]
Dependency Metrics ,[object Object]
Example - Coupling Package One Package Two Package Three Ca(Package One) = 1, Ce(Package One) = 2
Instability (I) ,[object Object],[object Object]
Stable  -> I = 0 -> Ce = 0
Unstable  -> I = 1 -> Ca = 0, Ce > 0
Should all categories be  stable ?
Why a  stable  category needs to be  extensible ? How?
Abstractness (A) ,[object Object]
Completely concrete  -> A = 0 -> no abstract classes in category
Is there a relationship between  Instability  and  Abstractness ?
Main Sequence
Distance From Main Sequence ,[object Object]
Agenda ,[object Object]
Examples of software metrics ,[object Object]
Object oriented metrics
Object oriented design quality metrics
Developer and team metrics
Developer and Team Metrics ,[object Object]
Productivity: Code Churn Metrics ,[object Object]

Weitere ähnliche Inhalte

Was ist angesagt?

Was ist angesagt? (20)

Software engineering : Layered Architecture
Software engineering : Layered ArchitectureSoftware engineering : Layered Architecture
Software engineering : Layered Architecture
 
Software myths | Software Engineering Notes
Software myths | Software Engineering NotesSoftware myths | Software Engineering Notes
Software myths | Software Engineering Notes
 
Software Measurement and Metrics.pptx
Software Measurement and Metrics.pptxSoftware Measurement and Metrics.pptx
Software Measurement and Metrics.pptx
 
Software Engineering : Requirement Analysis & Specification
Software Engineering : Requirement Analysis & SpecificationSoftware Engineering : Requirement Analysis & Specification
Software Engineering : Requirement Analysis & Specification
 
Object Oriented Design
Object Oriented DesignObject Oriented Design
Object Oriented Design
 
Lect4 software economics
Lect4 software economicsLect4 software economics
Lect4 software economics
 
Software design
Software designSoftware design
Software design
 
Software Project Management
Software Project ManagementSoftware Project Management
Software Project Management
 
Spm unit 2
Spm unit 2Spm unit 2
Spm unit 2
 
Lect2 conventional software management
Lect2 conventional software managementLect2 conventional software management
Lect2 conventional software management
 
Software project planning
Software project planningSoftware project planning
Software project planning
 
Design Concepts in Software Engineering-1.pptx
Design Concepts in Software Engineering-1.pptxDesign Concepts in Software Engineering-1.pptx
Design Concepts in Software Engineering-1.pptx
 
Spm life cycle phase
Spm life cycle phaseSpm life cycle phase
Spm life cycle phase
 
Software Project Management
Software Project ManagementSoftware Project Management
Software Project Management
 
Analysis modeling & scenario based modeling
Analysis modeling &  scenario based modeling Analysis modeling &  scenario based modeling
Analysis modeling & scenario based modeling
 
Software Engineering (Project Scheduling)
Software Engineering (Project Scheduling)Software Engineering (Project Scheduling)
Software Engineering (Project Scheduling)
 
software characteristics
software characteristicssoftware characteristics
software characteristics
 
Fundamental design concepts
Fundamental design conceptsFundamental design concepts
Fundamental design concepts
 
Software Evolution
Software EvolutionSoftware Evolution
Software Evolution
 
SWE-401 - 1. Introduction to Software Engineering
SWE-401 - 1. Introduction to Software EngineeringSWE-401 - 1. Introduction to Software Engineering
SWE-401 - 1. Introduction to Software Engineering
 

Ähnlich wie Software Measurement: Lecture 1. Measures and Metrics

Why computer programming
Why computer programmingWhy computer programming
Why computer programming
TUOS-Sam
 
A Validation of Object-Oriented Design Metrics as Quality Indicators
A Validation of Object-Oriented Design Metrics as Quality IndicatorsA Validation of Object-Oriented Design Metrics as Quality Indicators
A Validation of Object-Oriented Design Metrics as Quality Indicators
vie_dels
 
Search Engines
Search EnginesSearch Engines
Search Engines
butest
 
Unit 1 introduction to visual basic programming
Unit 1 introduction to visual basic programmingUnit 1 introduction to visual basic programming
Unit 1 introduction to visual basic programming
Abha Damani
 
se_lectures.DS_Store__MACOSXse_lectures._.DS_Storese_
se_lectures.DS_Store__MACOSXse_lectures._.DS_Storese_se_lectures.DS_Store__MACOSXse_lectures._.DS_Storese_
se_lectures.DS_Store__MACOSXse_lectures._.DS_Storese_
WilheminaRossi174
 
LCMC Session: Email and Web Conversion Success
LCMC Session: Email and Web Conversion SuccessLCMC Session: Email and Web Conversion Success
LCMC Session: Email and Web Conversion Success
BlueHornet
 
BMIS 530Systems Analysis and Redesign Project Phase 3Assignme
BMIS 530Systems Analysis and Redesign Project Phase 3AssignmeBMIS 530Systems Analysis and Redesign Project Phase 3Assignme
BMIS 530Systems Analysis and Redesign Project Phase 3Assignme
JeniceStuckeyoo
 
powerpoint
powerpointpowerpoint
powerpoint
butest
 
Software engineering
Software engineeringSoftware engineering
Software engineering
Fahe Em
 
Software engineering
Software engineeringSoftware engineering
Software engineering
Fahe Em
 

Ähnlich wie Software Measurement: Lecture 1. Measures and Metrics (20)

Software metrics
Software metricsSoftware metrics
Software metrics
 
Why computer programming
Why computer programmingWhy computer programming
Why computer programming
 
software engineering module i & ii.pptx
software engineering module i & ii.pptxsoftware engineering module i & ii.pptx
software engineering module i & ii.pptx
 
A Validation of Object-Oriented Design Metrics as Quality Indicators
A Validation of Object-Oriented Design Metrics as Quality IndicatorsA Validation of Object-Oriented Design Metrics as Quality Indicators
A Validation of Object-Oriented Design Metrics as Quality Indicators
 
Data Structures- Part1 overview and review
Data Structures- Part1 overview and reviewData Structures- Part1 overview and review
Data Structures- Part1 overview and review
 
Search Engines
Search EnginesSearch Engines
Search Engines
 
Slides chapter 15
Slides chapter 15Slides chapter 15
Slides chapter 15
 
Software maintenance
Software maintenanceSoftware maintenance
Software maintenance
 
Unit 1 introduction to visual basic programming
Unit 1 introduction to visual basic programmingUnit 1 introduction to visual basic programming
Unit 1 introduction to visual basic programming
 
Implementing Item Response Theory
Implementing Item Response TheoryImplementing Item Response Theory
Implementing Item Response Theory
 
se_lectures.DS_Store__MACOSXse_lectures._.DS_Storese_
se_lectures.DS_Store__MACOSXse_lectures._.DS_Storese_se_lectures.DS_Store__MACOSXse_lectures._.DS_Storese_
se_lectures.DS_Store__MACOSXse_lectures._.DS_Storese_
 
LCMC Session: Email and Web Conversion Success
LCMC Session: Email and Web Conversion SuccessLCMC Session: Email and Web Conversion Success
LCMC Session: Email and Web Conversion Success
 
Introduction.pptx
 Introduction.pptx Introduction.pptx
Introduction.pptx
 
BMIS 530Systems Analysis and Redesign Project Phase 3Assignme
BMIS 530Systems Analysis and Redesign Project Phase 3AssignmeBMIS 530Systems Analysis and Redesign Project Phase 3Assignme
BMIS 530Systems Analysis and Redesign Project Phase 3Assignme
 
powerpoint
powerpointpowerpoint
powerpoint
 
OOAD - Ch.09 - Software Project Estimation.pptx
OOAD - Ch.09 - Software Project Estimation.pptxOOAD - Ch.09 - Software Project Estimation.pptx
OOAD - Ch.09 - Software Project Estimation.pptx
 
Introduction to machine learning and model building using linear regression
Introduction to machine learning and model building using linear regressionIntroduction to machine learning and model building using linear regression
Introduction to machine learning and model building using linear regression
 
Software engineering
Software engineeringSoftware engineering
Software engineering
 
Software engineering
Software engineeringSoftware engineering
Software engineering
 
EE-232-LEC-01 Data_structures.pptx
EE-232-LEC-01 Data_structures.pptxEE-232-LEC-01 Data_structures.pptx
EE-232-LEC-01 Data_structures.pptx
 

Mehr von Programeter

Panel Discussion
Panel DiscussionPanel Discussion
Panel Discussion
Programeter
 

Mehr von Programeter (7)

Software Measurement: Lecture 3. Metrics in Organization
Software Measurement: Lecture 3. Metrics in OrganizationSoftware Measurement: Lecture 3. Metrics in Organization
Software Measurement: Lecture 3. Metrics in Organization
 
Software Measurement: Lecture 2. Function Point Analysis
Software Measurement: Lecture 2. Function Point AnalysisSoftware Measurement: Lecture 2. Function Point Analysis
Software Measurement: Lecture 2. Function Point Analysis
 
Panel Discussion
Panel DiscussionPanel Discussion
Panel Discussion
 
Software Outsourcing - Inkspin1 Experience
Software Outsourcing - Inkspin1 ExperienceSoftware Outsourcing - Inkspin1 Experience
Software Outsourcing - Inkspin1 Experience
 
What Can We Do Together?
What Can We Do Together?What Can We Do Together?
What Can We Do Together?
 
Russian Speaking Developers Best Match for Estonian Startups?
Russian Speaking Developers Best Match for Estonian Startups?Russian Speaking Developers Best Match for Estonian Startups?
Russian Speaking Developers Best Match for Estonian Startups?
 
Outsourcing for Startups
Outsourcing for StartupsOutsourcing for Startups
Outsourcing for Startups
 

Kürzlich hochgeladen

Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
Joaquim Jorge
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 

Kürzlich hochgeladen (20)

Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation Strategies
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 

Software Measurement: Lecture 1. Measures and Metrics