Unit 11: Software Metrics: Ð Lord Kelvin (Physicist) Ð Tom Demarco (Software Engineer)
Unit 11: Software Metrics: Ð Lord Kelvin (Physicist) Ð Tom Demarco (Software Engineer)
Unit 11: Software Metrics: Ð Lord Kelvin (Physicist) Ð Tom Demarco (Software Engineer)
Objective To describe the current state-of-the-art in the measurement of software products and process.
Why Measure?
"When you can measure what you are speaking about and express it in numbers, you know something about it; but when you cannot measure it, when you cannot express it in numbers, your knowledge is of a meagre and unsatisfactory kind: it may be the beginnings of knowledge but you have scarcely in your thoughts advanced to the stage of Science." Lord Kelvin (Physicist) "You cannot control what you cannot measure." Tom DeMarco (Software Engineer)
What is Measurement
measurement is the process by which numbers or symbols are assigned to attributes of entities in the real world in such a way as to describe them according to clearly defined unambiguous rules
Attribute
Defects discovered in design reviews Number of pages Number of lines of code, number of operations Team size, average team experience
Types of Metric
direct measurement eg number of lines of code indirect/ derived measurement eg defect density = no. of defects in a software product / total size of product prediction eg predict effort required to develop software from measure of the functionality function point count
Types of Metric
nominal eg no ordering, simply attachment of labels (language: 3GL, 4GL) ordinal eg ordering, but no quantitative comparison (programmer capability: low, average, high)
Types of Metric
interval eg between certain values (programmer capability: between 55th and 75th percentile of the population ability) ratio eg (the proposed software is twice as big as the software that has just been completed) absolute eg the software is 350,000 lines of code long
Types of Metric
product metrics size metrics complexity metrics quality metrics process metrics resource metrics project metrics
A Metrics Programme
software development organisations should have a metrics programme in order to: calibrate models that can be used to forecast project/product behaviour give measures that can be used to control the software development process involves metrics AND data collection
Question
Subquestion
Subquestion
Metric
cyclomatic complexity
design metrics
Data Collection
instrument the process can be supported by off-the-shelf tools, for example Krakatau for Java Krakatau supports a full range of object-oriented, procedural, language specific, complexity and size metrics for C/C++ and Java. supported metrics include Cyclomatic Complexity, Enhanced Cyclomatic Complexity, Halstead Software Science metrics, LOC metrics and MOOD metrics. In all over 70 metrics are offered
Key Points
To survive a software development organisation must make accurate cost estimates and improve productivity and quality. If you do not know where you are now you certainly won't know where you will be in the future. To achieve accurate measurements of productivity and quality requires metrics collection and analysis.
10