You are on page 1of 15

Software Metric

….contd.
• A software metric is a quantitative measure of a degree to which a
software system or process possesses some property.
• The goal is obtaining objective, reproducible and quantifiable
measurements, which may have numerous valuable applications in
schedule and budget planning, cost estimation, quality assurance
testing, software debugging, software performance optimization, and
optimal personnel task assignments.
Popular Metrics
• Two popular metrics used to estimate the size of software project :
lLine Of Code (LOC)
• lFunction Point (FP)
Line Of Code Metric
• LOC metric is a software metric used to measure the size of a
computer program by counting the number of lines in the text of the
program's source code.
• Lines used for commenting the code and header file are ignored.
• LOC is typically used to predict the amount of effort that will be
required to develop a program, as well as to estimate programming
productivity or maintainability once the software is produced.
Types of LOC
• Two major types of LOC :
• Physical LOC
• No. of line of code
• Logical LOC
• No. of executable statements.
Physical LOC
• Physical LOC is the count of lines in the text of the program's source
code including comment lines.
• Blank lines are also included unless the lines of code in a section
consists of more than 25% blank lines.
Logical LOC
• Logical LOC attempts to measure the number of executable
statements, but their specific definitions are tied to specific computer
languages.
• Example: Logical LOC measure for C-like programming languages is
the number of statement-terminating semicolons(;)
Difference
Advantage
• Scope for Automation of Counting
• An Intuitive Metric
• Ubiquitous Measure
Disadvantage
• Lack of Accountability
• Lack of Cohesion with Functionality
• Adverse Impact on Estimation
• Developer’s Experience
• Psychology
Function Point Metric
• Function points measure software size.
• A function point is a unit of measurement to express the amount of
business functionality an information system (as a product) provides
to a user.
• Function points were defined in 1979 in Measuring Application
Development Productivity by Allan Albrecht at IBM
FP Metrics
The functional user requirements of the software are identified and
each one is categorized into one of five types:
inputs,
outputs,
inquiries,
internal files, and
external interfaces
Functional Requirements of Software
• Inputs : Each data item given by user except user inquiries.
• Output : Reports printed, Screen output, error message produced etc.
Inquiries : Inquiries are user command which require specific action
by user.
• Internal Files : It contains data structure and physical files.
• External Interfaces : Interfaces are used to exchange information with
external system or external data source eg. : CD-ROM
Function Point
• It is computed in three step:
• Computing Unadjusted Function Point (UFP)
• Refining to show the complexity of UFP
• Refining each FP characteristic to influence the development effort of
project.
• UFP = (Inputs)*4 + (Outputs)*5 + (Inquiries)*4 + (Files)*10 +
(Interfaces)*10

You might also like