Software Engineering
Software Engineering
Software Metrics
Objectives
• Provide regular feedback to the individuals and teams who have worked to
collect measures and metrics.
• Work with practitioners and teams to set clear goals and metrics that will be
used to achieve them
• Metrics data that indicate a problem area should not be considered “negative.”
These data are merely an indicator for process improvement
• Normalization approaches:
Size oriented (lines of code approach)
• Size-Oriented:
errors per KLOC (thousand lines of code), defects per KLOC, R per LOC, page of documentation
per KLOC, errors / person-month, LOC per person-month, R / page of documentation
• Function-Oriented:
errors per FP, defects per FP, R per FP, pages of documentation per FP, FP per person-month
Why Opt for FP Measures?
• Independent of programming language. Some programming
languages are more compact, e.g. C++ vs. Assembler
• Use readily countable characteristics of the “information domain”
of the problem
• Does not “penalize” creative implementations that require fewer
LOC than others
• Makes it easier to accommodate reuse and object-oriented
approaches
• Original FP approach good for typical Information Systems
applications (interaction complexity)
• Variants (Extended FP and 3D FP) more suitable for real-time and
scientific software (algorithm and state transition complexity)
Computing Function Points
Analyze information
domain of the
Establish count for input domain and system
application and
develop counts
interfaces
FP = SUM(count x weight) x C
Compute function where complexity multiplier C = (0.65+0.01
points x N) degree of influence N = SUM(F_i)
Analyzing the Information
Domain
weighting factor
measurement parameter count simple avg. complex
number of user inputs X 3 4 6 =
number of user outputs X 4 5 7 =
number of user inquiries X 3 4 6 =
number of files X 7 10 15 =
number of ext.interfaces X 5 7 10 =
count-total
complexity multiplier
function points
Taking Complexity into Account
• Complexity Adjustment Values (F_i) are rated on a scale of 0 (not important) to
5 (very important):
• Does the system require reliable backup and recovery?
• Are data communications required?
• Are there distributed processing functions?
• Is performance critical?
• System to be run in an existing, heavily utilized environment?
• Does the system require on-line data entry?
• On-line entry requires input over multiple screens or operations?
• Are the master files updated on-line?
• Are the inputs, outputs, files, or inquiries complex?
• Is the internal processing complex?
• Is the code designed to be reusable?
• Are conversion and instillation included in the design?
• Multiple installations in different organizations?
• Is the application designed to facilitate change and ease-of-use?
Exercise: Function Points
• Compute the function point value for a project with the
following information domain characteristics:
• Number of user inputs: 32
• Number of user outputs: 60
• Number of user enquiries: 24
• Number of files: 8
• Number of external interfaces: 2
• Assume that weights are average and external complexity adjustment
values are not important.
• Answer:
(32 4 60 5 24 4 8 10 2 7) 0.65 401.7
Example: SafeHome Functionality
Test Sensor
Password
Zone Setting Sensors
Zone Inquiry
Monitor
Password, Alarm Alert and
Sensors, etc. Response
System
System
Config Data
Example: SafeHome FP Calc
weighting factor
measurement parameter count simple avg. complex
number of user inputs 3 X 3 4 6 = 9
number of user outputs 2 X 4 5 7 = 8
number of user inquiries 2 X 3 4 6 = 6
number of files 1 X 7 10 15 = 7
number of ext.interfaces 4 X 5 7 10 = 22
count-total 52
complexity multiplier[0.65 0.01 F ] [0.65 0.46]
i 1.11
function points 58
Exercise: Function Points
• Compute the function point total for your project. Hint: The
complexity adjustment values should be low(Fi 10 )
• Some appropriate complexity factors are (each scores 0-5):
1. Is performance critical?
2. Does the system require on-line data entry?
3. On-line entry requires input over multiple screens or operations?
4. Are the inputs, outputs, files, or inquiries complex?
5. Is the internal processing complex?
6. Is the code designed to be reusable?
7. Is the application designed to facilitate change and ease-of-use?