Wendy is a randomly chosen member of a large female population, in which 9% are pregnant. Wendy tests positive in a pregnancy test. Pregnancy test correctly identifies pregnancy 95% of the time and correctly identifies non pregnancy 92% of the time. What is the probability that Wendy is pregnant given the positive test result ?

To find the probability that Wendy is pregnant given a positive test result, we can use Bayes' theorem.

Let's define the events:
A = Wendy is pregnant
B = Wendy tests positive

We want to find P(A|B), which represents the probability that Wendy is pregnant given a positive test result. According to Bayes' theorem:

P(A|B) = (P(B|A) * P(A)) / P(B)

P(B|A) represents the probability of a positive test result given that Wendy is pregnant. From the information given, we know that the pregnancy test correctly identifies pregnancy 95% of the time. Therefore, P(B|A) = 0.95.

P(A) represents the probability that a randomly chosen member of the large female population is pregnant. From the information given, we know that 9% of the population is pregnant. Therefore, P(A) = 0.09.

P(B) represents the probability of getting a positive test result. We need to compute this probability using the information given.

To do this, we need to consider two cases:
1. Wendy is pregnant and tests positive (P(B and A)).
2. Wendy is not pregnant and tests positive (P(B and not A)).

Using conditional probability, we can express P(B) as follows:
P(B) = P(B and A) + P(B and not A)

Since we know that P(B and A) = P(B|A) * P(A), we can substitute the values:
P(B) = (P(B|A) * P(A)) + P(B and not A)

To find P(B and not A), we need to calculate the probability of testing positive when Wendy is not pregnant. From the information given, we know that the test also correctly identifies non-pregnancy 92% of the time. Therefore, P(B and not A) = P(B|not A) * P(not A).

P(B|not A) represents the probability of a positive test result given that Wendy is not pregnant. Since the test correctly identifies non-pregnancy 92% of the time, P(B|not A) = 0.92. Additionally, P(not A) = 1 - P(A) = 1 - 0.09 = 0.91.

Substituting these values back into the equation for P(B):
P(B) = (P(B|A) * P(A)) + (P(B|not A) * P(not A))
= (0.95 * 0.09) + (0.92 * 0.91)

Now we have all the values we need to find P(A|B) using Bayes' theorem:
P(A|B) = (P(B|A) * P(A)) / P(B)
= (0.95 * 0.09) / [(0.95 * 0.09) + (0.92 * 0.91)]

Calculating this expression will give us the final probability that Wendy is pregnant given the positive test result.