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 a Bayesian spam filter is trained on a set of\({\bf{500}}\)spam messages and\({\bf{200}}\)messages that are not spam. The word “exciting” appears in\({\bf{40}}\)spam messages and in\({\bf{25}}\)messages that are not spam. Would an incoming message be rejected as spam if it contains the word “exciting” and the threshold for rejecting spam is\({\bf{0}}.{\bf{9}}\)?

Short Answer

Expert verified

Answer

Hence, the incoming message containing the word ‘exciting’ is not rejected as spam.

Step by step solution

01

Given Data

  • A Bayesian spam filter is trained on a set of \(500\) spam messages and \(200\) messages that are not spam. The word “exciting” appears in \(40\) spam messages and in \(25\) messages that are not spam.
02

Formula to be used

According to Bayes’ theorem, \(P\left( {F\left| E \right.} \right) = \frac{{P\left( {E\left| F \right.} \right)P\left( F \right)}}{{P\left( {E\left| F \right.} \right)P\left( F \right) + P\left( {E\left| {\overline F } \right.} \right)P\left( {\overline F } \right)}}\)

03

find the message category

Assume the following events-

\(E\)is a received message contains the word ‘exciting’.

\({F_1}\)is that an incoming message is spam and\({F_2}\)is that the message received is not a spam.

Thus, the probability for a message received containing the word ‘exciting’ to be a spam is-

\(\begin{array}{l}P\left( {{F_1}\left| E \right.} \right) = \frac{{P\left( {E\left| {{F_1}} \right.} \right)P\left( {{F_1}} \right)}}{{P\left( {E\left| {{F_1}} \right.} \right)P\left( {{F_1}} \right) + P\left( {E\left| {{F_2}} \right.} \right)P\left( {{F_2}} \right)}}\\ = \frac{{\left( {\frac{{40}}{{500}}} \right)\left( {\frac{{500}}{{700}}} \right)}}{{\left( {\frac{{40}}{{500}}} \right)\left( {\frac{{500}}{{700}}} \right) + \left( {\frac{{25}}{{200}}} \right)\left( {\frac{{200}}{{700}}} \right)}}\\ = \frac{8}{{13}}\\ = 0.61538 < 0.9\end{array}\)

So, the incoming message is not rejected as spam.

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: Use mathematical induction to prove that E1,E2,...,En is a sequence of n pair wise disjoint events in a sample space S, where nis a positive integer, then p(i=1nEi)=i=1np(Ei).

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

Question: A space probe near Neptune communicates with Earth using bit strings. Suppose that in its transmissions it sends a 1 one-third of the time and a 0 two-thirds of the time. When a 0 is sent, the probability that it is received correctly is 0.9, and the probability that it is received incorrectly (as a 1) is 0.1. When a 1 is sent, the probability that it is received correctly is 0.8, and the probability that it is received incorrectly (as a 0) is 0.2

a) Find the probability that a 0 is received.

b) Use Hayes theorem to find the probability that a 0 was transmitted, given that a 0 was received.

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.

Question: What is the expected sum of the numbers that appear on two dice, each biased so that a 3 comes up twice as often as each other number?

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