Warning: foreach() argument must be of type array|object, bool given in /var/www/html/web/app/themes/studypress-core-theme/template-parts/header/mobile-offcanvas.php on line 20

Question: Suppose that we have prior information concerning whether a random incoming message is spam. In particular, suppose that over a time period, we find that s spam messages arrive and h messages arrive that are not spam.

a) Use this information to estimate p(S), the probability that an incoming message is spam, and\(p(\bar S)\), the probability an incoming message is not spam.

b) Use Bayes’ theorem and part (a) to estimate the probability that an incoming message containing the word w is spam, where p(w)is the probability that w occurs in a spam message and q(w) is the probability that w occurs in a message that is not spam.

Short Answer

Expert verified

Answer:

(a)\(p(S) = \frac{s}{{s + h}}\) and \(p(\bar S) = \frac{h}{{s + h}}\)

(b) The probability that an incoming message containing the word w is spam is \(\frac{{p(w).s}}{{p(w).s + q(w).h}}\)

Step by step solution

01

Given

We have prior information concerning whether a random incoming message is spam. In particular, suppose that over a time period, we find that s spam messages arrive and h messages arrive that are no spam.

02

Formula

Bayes’ Formula:

\(P(F/E) = \frac{{P(E/F)P(F)}}{{P(E/F)P(F) + P(E/\bar F)P(\bar F)}}\)

03

Calculation for part(a)

We have\(p(S) = \frac{s}{{s + h}}\)and

\(\begin{array}{l}p(\bar S) = 1 - p(S)\\ = 1 - \frac{s}{{s + h}}\\ = \frac{{s + h - s}}{{s + h}}\\ = \frac{h}{{s + h}}\end{array}\)

04

Final Answer for part(a)

Hence,

\(p(S) = \frac{s}{{s + h}}\)and \(p(\bar S) = \frac{h}{{s + h}}\)

05

Calculation for part(b)

The probability that an incoming message containing the word w is spam is

\(\frac{{p(E/S).p(S)}}{{p(E/S).p(S) + p(E/\bar S).p(\bar S)}} = \frac{{p(w).s}}{{p(w).s + q(w).h}}\)

Here p(w)is the probability that w occurs in a spam message and q(w) is the probability that w occurs in a message that is not spam.

06

Final Answer for part(b)

The probability that an incoming message containing the word w is spam is\(\frac{{p(w).s}}{{p(w).s + q(w).h}}\)

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

Question 2. To show

If eventsEandFare independent, then events E¯and F¯are also independent.

Question:Ramesh can get to work in three different ways: by bicycle, by car, or by bus. Because of commuter traffic, there is a\({\bf{50}}\% \)chance that he will be late when he drives his car. When he takes the bus, which uses a special lane reserved for buses, there is a\({\bf{20}}\% \)chance that he will be late. The probability that he is late when he rides his bicycle is only\({\bf{5}}\% \). Ramesh arrives late one day. His boss wants to estimate the probability that he drove his car to work that day.

a) Suppose the boss assumes that there is a\({\bf{1}}/{\bf{3}}\)chance that Ramesh takes each of the three ways he can get to work. What estimate for the probability that Ramesh drove his car does the boss obtain from Bayes’ theorem under this assumption?

b) Suppose the boss knows that Ramesh drives\(3{\bf{0}}\% \)of the time, takes the bus only\({\bf{10}}\)% of the time, and takes his bicycle\({\bf{60}}\% \)of the time. What estimate for the probability that Ramesh drove his car does the boss obtain from Bayes’ theorem using this information?

Question:To determine which is more likely: rolling a total of 8 when two dice are rolled or rolling a total of 8 when three dice are rolled.

Question 23. To determine

What is the conditional probability that exactly four heads appear when a fair coin is flipped five times, given that the first flip came up heads?

Question 2. To determine

  1. What probability distribution for birthday’s should be used to reflect how often February29occurs?
  2. What is the probability that in a group ofnpeople at least two have the same birthday using the probability distribution froma?
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