Let’s look at a few examples.
Suppose the accuracy rate of the test is 99% both ways…the test will give you correct results 99% of the time.
Suppose we run the test on 1000 people and 500 people in the group are positive. That means of the 500 positive people, 495 are correctly told they are positive, 5 people are mistakenly told they are negative. Of the 500 negative people, 495 are told they are negative, but 5 are mistakenly told they are postive. So, if you are told you are negative, what are the odds that you aren’t really negative? 500 people were told they were negative (495 + 5), 5 of those are mistakes, so 5/500, or .01. If you’re told you’re positive, what are the odds that you aren’t really positive? 5/500, or .01.
Now, lets look at test group of 1000 people where 100 people are positive. That means of 100 positive people, 99 are correctly told they are positive, 1 person is incorrectly told they are negative. Of the 900 negative people, 891 are correctly told they are negative, 9 people are mistakenly told they are positive. So if you are told you are negative, what are the odds that you aren’t really negative? 892 people are told they are negative, there was 1 mistake, so the odds are 1/892 or 0.00112, or 1/10 of 1 percent. If you’re told you’re positive, what are the odds that you aren’t really positive? 108 people were told they were positive, there were 9 mistakes, so the odds are 9/108, or .0833, or 8 percent. Even though the test is 99 percent accurate, we have a false positive rate much greater than that, 8 percent.
Now let’s see what happens at the extreme case, 1000 tests, only 1 person is really positive. That person is told they are positive (well, .99 people are told they are positive, we could make it come out an integer by testing 100,000 people but that’s not important). There are .01 people told they are negative by mistake. Of the 999 people who are negative, 999 * .99 = 989.01 people are correctly told they are negative, 9.99 people are mistakenly told they are positive. If you’re told you’re negative, what are the odds that you’re really positive? 989.02 people are told they are negative, .01 is really positive, so .01/989.02, or .0000101. Vanishingly small. But what about the false positive rate? 10.98 people were told they were positive, but only .99 actually are. So the false positive rate is 10.98/.99, or 11.1. Meaning, if you’re told you’re positive, only 1 time in 11 is that actually true. This test that’s 99% accurate in determining whether you’re positive or negative gives far more false positives than it does true positives!
We’ll also get different numbers if the test isn’t symetrically accurate, the test might be 99.99% accurate detecting positive people and 99% accurate detecting negative people, or vice versa. But if the number of positive people is small relative to the sample size then we’re going to get more false positives than true positives.
This is the reason you see science/health stories arguing about whether early screening for things like prostate cancer are worthwhile. If the incidence of disease is really low in the tested population, and the test is only 99% accurate, you’ll have lots and lots of false positives. You can’t treat everyone who tests positive, even with a 99% accurate test because you know that most of those are false positives. You need to do a second completely independent test to detect the true positives in the sea of false positives, and if that test doesn’t exist (or is extremely expensive/invasive) then screening for rare diseases is useless even with very accurate tests.