A particular genetic trait occurs in 2% of the population. The reliability of a test to discover the trait is: if the person has the trait then the test is positive 98% of the time, but the test is also positive 3% of the time for those that do not have the

trait.
a)Construct a tree diagram to represent the population and the testing reliability for the genetic trait
b)if a person is selected at random, what is the probability that the person has the trait, given that he tested positive?

Please verify if my tree diagram is correct:
/positive- have trait
-do not have trait
a)population- trait
-no trait
\negative
/ \
have trait do not have trait
b)0.2x0.98=0.196
Thanks in advance

A tree diagram includes the related probabilities, which is the real purpose of the tree diagram, because it then enables us to get the probability of each situation.

            /positive(0.98*0.02=0.0196)
    trait(0.02)-- negative(0.02*0.02=0.0004)
/
\
    no trait(0.98) -- positive (0.03*0.98=0.0294)
            \ negative(0.97*0.98=0.9506)
Sum of all probabilities=1.0 √

For part (b), it is a conditional probability, so the sample space is among those that test positive, namely, 0.0196+0.0294=0.0490.
Out of these, 0.0196 has the trait, so P(T|+)=0.0196/0.0490

Thank you very much for you help and explanations.

You're welcome!

a) Your tree diagram is mostly correct, but there are a few modifications needed. Here is the corrected version:

/-------------- Positive: Have Trait (0.02 * 0.98)
Population
\-------------- Positive: No Trait (0.98 * 0.03)

/-------------- Negative: Have Trait (0.02 * 0.02)
No Trait
\-------------- Negative: No Trait (0.98 * 0.97)

b) To find the probability that a person has the trait given that they tested positive, we need to use Bayes' theorem. Let's denote "H" as the event of having the trait, and "P" as the event of testing positive.

We need to find P(H|P), which is the probability of having the trait (H) given that the test is positive (P). Bayes' theorem states:

P(H|P) = (P(P|H) * P(H)) / P(P)

P(P|H) is the probability of testing positive (P) given that the person has the trait (H), which is 0.98.
P(H) is the probability of having the trait, which is 0.02.
P(P) is the probability of testing positive, which is the sum of the probabilities of testing positive in both cases (having the trait and not having the trait).

P(P) = P(P|H) * P(H) + P(P|not H) * P(not H)
P(P) = 0.98 * 0.02 + 0.03 * 0.98

Now we can substitute these values into Bayes' theorem:

P(H|P) = (0.98 * 0.02) / (0.98 * 0.02 + 0.03 * 0.98)

Calculating the expression, we find:

P(H|P) = 0.02 / (0.0196 + 0.0294) = 0.02 / 0.049 = 0.40816

Therefore, the probability that a person has the trait, given that they tested positive, is approximately 0.408 or 40.8%.