ABSTRACT

In Chapter 5 we discussed primitive software metrics. These were atomic measures of a program module. They measured a single program attribute. Derived software measures, on the other hand, are linear and nonlinear composites of metric primitives. We might think to create a new measure of program module size such that Size = Exec + LOC. Unfortunately, life is not that simple. We will not benefit from our new size metric. In fact, we will probably lose information in the sum of module executable statement and lines of code. The metrics Exec and LOC are drawn from different populations. They are measured in different units. And they are also highly correlated. This exercise is somewhat akin to our creating a size measure from human attributes. Consider the following new size measure: Health = Height + Weight. To compute our new Health metric we will measure an individual’s height and his or her weight and then add them together. We might speculate that the larger the value of Health, the fewer medical problems an individual will have. Immediately, common sense kicks in. We know that you cannot add these two values. Height is measured in centimeters and weight is measured in kilograms. These two attributes are measured in different units. Finally, the relationship between our new Health metric and a person’s actual well-being is purely speculative. The basic principles of science would demand that we validate our Health metric with an empirical investigation before we make any health assertions about our new metric.