Software defects in NASA spacecraft instrument code. Portions of computer software code that may contain undetected defects are called blind spots. The issue of blind spots in software code evaluation was addressed at the 8th IEEE International Symposium on High AssuranceSoftware Engineering (March 2004). The researchers developed guidelines for assessing methods of predicting software defects using data on 498 modules of software code written in “C” language for a NASA spacecraft instrument. One simple prediction algorithm is to count the lines of code in the module; any module with more than 50 lines of code is predicted to have a defect. The accompanying file contains the predicted and actual defect status of all 498 modules. A standard approach to evaluating a software defect prediction algorithm is to form a two-way summary table similar to the one shown here. In the table, a, b, c, and d represent the number of modules in each cell. Software engineers use these table entries to compute several probability measures, called accuracy, detection rate, false alarm rate, and precision.

a. Accuracy is defined as the probability that the prediction algorithm is correct. Write a formula for accuracyas a function of the table values a, b, c, and d.

b. The detection rate is defined as the probability that the algorithm predicts a defect, given that the module actually is a defect. Write a formula for detection rate as a function of the table values a, b, c, and d.

c. The false alarm rate is the probability that the algorithm predicts a defect, given that the module has no defect. Write a formula for false alarm rates as a function of the table values a, b, c, and d.

d. Precision is defined as the probability that the module has a defect, given that the algorithm predicts a defect. Write a formula for precision as a function of the table values a, b, c, and d.

e. Access the accompanying file and compute the accuracy, detection rate, false alarm rate, and precision values. Interpret the results.

Short Answer

Expert verified
  1. The probability isP=a+da+b+c+d
  2. The probability isP=db+d
  3. The probability isP=ca+c
  4. The probability isP=dc+d
  5. The values of accuracy, detection rate, false alarm rate, and precision are84.34%,40.82%,10.91%and28.99%

Step by step solution

01

Important formula

The formula for probability isP=favourableoutcomestotaloutcomes

02

(a) The probability that the prediction algorithm is correct

Here the outcomes are a, b, c, d., and thefavorable outcome are a and d.

So, the probability is P=a+da+b+c+d.

03

(b) Write a formula for detection rate as a function of the table values a, b, c, and d

Here the outcomes are b, d. and the favorable outcome is d.

Thus, the probability is P=db+d.

04

(c) Write a formula for false alarm rate as a function of the table values a, b, c, and d

Here the outcomes are a, c., and the favorable outcome is c.

Hence, the probability isP=ca+c .

05

(d) Write a formula for precision as a function of the table values a, b, c, and d

Here the outcomes are c, d, and the favorable outcome is d.

Accordingly, the probability isP=dc+d .

06

(e) Access the accompanying file and compute the accuracy, detection rate, false alarm rate, and precision values. Interpret the results

From the algorithms, the values are:

The value for accuracy:

P=a+da+b+c+d=400+20400+29+49+20=420498=84.34%

The value for detection rate:

P=db+d=2029+20=40.82%

The value for false alarm rate:

P=ca+c=49400+49=10.91%

The value for precision:

P=ca+c=49400+49=10.91%

Therefore, the values of accuracy, detection rate, false alarm rate, and precision are 84.34%,40.82%,10.91%and28.99%.

Unlock Step-by-Step Solutions & Ace Your Exams!

  • Full Textbook Solutions

    Get detailed explanations and key concepts

  • Unlimited Al creation

    Al flashcards, explanations, exams and more...

  • Ads-free access

    To over 500 millions flashcards

  • Money-back guarantee

    We refund you if you fail your exam.

Over 30 million students worldwide already upgrade their learning with Vaia!

One App. One Place for Learning.

All the tools & learning materials you need for study success - in one app.

Get started for free

Most popular questions from this chapter

Two fair dice are tossed, and the following events are defined:

A: {Sum of the numbers showing is odd.}

B: {Sum of the numbers showing is 9, 11, or 12.}

Are events A and B independent? Why?

Chance of an Avon sale.The probability that an Avon salesperson sells beauty products to a prospective customer on the first visit to the customer is .4. If the salesperson fails to make the sale on the first visit, the probability that the sale will be made on the second visit is .65. The salesperson never visits a prospective customer more than twice. What is the probability that the salesperson will make a sale to a particular customer?

Jamming attacks on wireless networks. Refer to the International Journal of Production Economics (Vol. 172, 2016) study of U.S. military jamming attacks on wireless networks used by terrorists, Exercise 2.8 (p. 73). Recall that 80 recent jamming attacks were classified according to network type (WLAN, WSN, or AHN) attacked and the network's number of channels (single- or multi-channel). The results are reproduced in the accompanying table.

a. Find the probability that a recent jamming attack involved a single-channel network.

b. Find the probability that a recent jamming attack involved a WLAN network.


Network Type/Number of Channels

Number of Jamming Attacks

WLAN / Single

31

WSN / Single

13

AHN / Single

8

WLAN / Multi

14

WSN / Multi

9

AHN / Multi

5

TOTAL

80

Source: S. Vadlamani et al., "Jamming Attacks on Wireless Networks: A Taxonomic Survey, "International Journal of Production Economics, Vol. 172, 2016 (Figure 6)

The diagram below describes the sample space of a particular experiment and events A and B .

  1. What is this type of diagram called?
  2. Suppose the sample points are equally likely. Find PAand PB.
  3. Suppose P1=P2=P3=P4=116and P5=P6=P7=P8=P9=P10=18 . Find PAand PB.

Is a product “green”?A “green” product (e.g., a productbuilt from recycled materials) is one that has minimal impact on the environment and human health. How do consumers determine if a product is “green”? The 2011

ImagePower Green Brands Survey asked this question of more than 9,000 international consumers. The results are shown in the following table.

Reason for saying a product is green

Percentage of consumers

Certification mark on label

45

Packaging

15

Reading information about the product

12

Advertisement

6

Brand we site

4

Other

18

Total

100

a.What method is an international consumer most likely to use to identify a green product?

b.Find the probability that an international consumer identifies a green product by a certification mark on the product label or by the product packaging.

c.Find the probability that an international consumer identifies a green product by reading about the product or from information at the brand’s Web site.

d.Find the probability that an international consumer does not use advertisements to identify a green product.

See all solutions

Recommended explanations on Math Textbooks

View all explanations

What do you think about this solution?

We value your feedback to improve our textbook solutions.

Study anywhere. Anytime. Across all devices.

Sign-up for free