Every result you act on in fish health is a test result: a PCR from 20 fish, a histology report, a gill score, a mortality code, a model's risk score. None of them are perfect. Good decisions start with knowing how each one is imperfect.
Epidemiologists use a small set of numbers to describe this. They're simple once you see them laid out, and they explain some things that otherwise feel paradoxical, like why a "good" test can be wrong most of the time.
Four Possible Outcomes
Every time a test meets reality, one of four things happens:
| Disease really present | Disease really absent | |
|---|---|---|
| Test positive | True positive (TP) | False positive (FP) |
| Test negative | False negative (FN) | True negative (TN) |
Every measure below is a different way of reading this table.
Sensitivity and Specificity: The Two Properties of the Test
Sensitivity (Se): of the fish that really have the disease, the share the test flags. A highly sensitive test rarely misses. A negative result from it is reassuring.
Se = TP / (TP + FN)
Specificity (Sp): of the fish that really don't have the disease, the share the test correctly leaves unflagged. A highly specific test rarely raises false alarms. A positive result from it carries weight.
Sp = TN / (TN + FP)
These two describe the test itself. They're measured against a reference standard. When no perfect reference exists, which is common in aquaculture, they're estimated by comparing several tests across populations with different infection levels (Bayesian latent class analysis).
Two caveats that matter in practice:
- There's always a trade-off. Most tests and every risk score have a cut-off: a Ct value, a score level, a gill score. Make it easier to call a result positive and sensitivity goes up while specificity goes down. Make it stricter and the reverse happens. There's no free lunch, only a choice about which error costs you more.
- "Fixed" is relative. Se and Sp don't change with prevalence, but they can drift with the stage of infection, the life stage of the fish, season and sampling. Early in an outbreak, when viral loads are low, a test that's excellent on clinical cases can miss more often.

There's a third button labelled "perfect test". It isn't connected to anything.
Predictive Values: The Two Questions Teams Actually Ask
At the cage side, you don't know whether the disease is present. That's why you tested. You know the result, and you want to know what it means.
Positive predictive value (PPV): of the fish that test positive, the share that really have the disease. "It came back positive. How likely is it real?"
PPV = TP / (TP + FP)
Negative predictive value (NPV): of the fish that test negative, the share that really are free of it. "It came back negative. Can I relax?"
NPV = TN / (TN + FN)
When colleagues ask "how accurate is it?", they usually mean PPV. Strictly speaking, accuracy is a separate number: the share of all results that are correct. For rare diseases it's misleading, because true negatives dominate it. You'll see why in the next section.
Glossary note: data-science reports often use different names for the same things. Recall is sensitivity. Precision is PPV.
Why Predictive Values Depend on Prevalence
Sensitivity and specificity belong to the test. Predictive values belong to the test and the population. Specifically, they depend on how common the disease is where you're testing (the prevalence, or pre-test probability).
Here's a worked example, using counts rather than percentages because they're easier to follow.
Picture 1,000 fish tested one by one. 3% really have the disease. The test has 90% sensitivity and 90% specificity.
| Diseased (30) | Healthy (970) | Total | |
|---|---|---|---|
| Test positive | 27 | 97 | 124 |
| Test negative | 3 | 873 | 876 |
- The test catches 27 of the 30 diseased fish. That's the 90% sensitivity.
- It correctly clears 873 of the 970 healthy fish. That's the 90% specificity.
- But 97 healthy fish are also flagged. Because healthy fish far outnumber sick ones, these false alarms outnumber the 27 true positives.
PPV = 27 / 124 ≈ 22%. A positive result from this "90% test" is right only about one time in five. NPV = 873 / 876 ≈ 99.7%. A negative result is very reliable. Accuracy = (27 + 873) / 1,000 = 90%. The test is "90% accurate", and still most of its positives are wrong.
Now run the same test where the disease is more common:
| Prevalence | PPV | NPV |
|---|---|---|
| 20% | 69% | 97% |
| 5% | 32% | 99.4% |
| 3% | 22% | 99.7% |
Same test, Se 90% and Sp 90% throughout.
With real numbers. A Norwegian Veterinary Institute field study of tests for salmonid alphavirus (the cause of PD) estimated, per fish, that real-time RT-PCR has about 98% sensitivity but 83% specificity, and histopathology about 64% sensitivity and 97% specificity (Jansen et al., 2019). At 3% prevalence, a positive PCR on a single fish would be right only about 15% of the time. At 20% prevalence it would be right about 59% of the time. The PCR is an excellent screen, which is exactly why the authors recommend confirming weak positives.
Some lessons from the field:

Han Solo, on hearing that a positive from a "90% test" is 90% likely to be real.
- For rare diseases, most positives will be false alarms, even with a good test. That's just how arithmetic works. It doesn't mean the test is broken.
- The same result means different things on different sites. A positive at a site with an ongoing outbreak nearby is worth more than the same positive at a site with no history.
- Success makes tests look worse. As biosecurity improves and a disease gets rarer, PPV falls even though the test hasn't changed. Judge a test by its sensitivity and specificity, and by whether it helps you decide. Don't judge it by its hit rate alone.
How Much Does the Result Shift the Odds?
Rather than "is the test right?", ask: "how much should this result change what I believed before?"
That's the idea behind pre-test and post-test probability:
- Pre-test probability: how likely the disease was before the result. It comes from the site's history, the season, the fish's life stage, the neighbours, clinical signs.
- Post-test probability: how likely it is after the result.
The bridge between them is the likelihood ratio:
- LR+ = Se / (1 − Sp): how many times more likely a positive is in a diseased fish than in a healthy one.
- LR− = (1 − Se) / Sp: the same for a negative result.
For our 90/90 test, LR+ = 9 and LR− ≈ 0.11. So a positive multiplies the odds of disease by 9, and a negative divides them by about 9. (Odds are not the same as probability: 3% is odds of about 1 to 32.)
Starting from 3%, a positive takes you to about 22%. That's the PPV again, reached another way. A negative takes you to about 0.3%.
Why bother with this framing? It matches how vets already reason. A test result never replaces judgement. It updates it. A result that moves a fish, a pen or a site from 3% to 22% is very useful information even though it's "wrong" four times out of five. It turns something you'd ignore into something you should look at.
Pens and Sites Are Not Single Fish: Group-Level Testing
So far we've treated each fish as the unit. In practice we rarely diagnose individual fish. We sample a few and draw conclusions about the pen or the site. That adds a second layer of uncertainty.
Group-level sensitivity: the chance that a sample of n fish includes at least one positive, when the group is truly infected. Assuming a large population, random sampling, and no false positives:
Group Se = 1 − (1 − p × Se)n
where p is the within-pen prevalence and Se is the per-fish sensitivity.
For a 20-fish PCR with 95% per-fish sensitivity:
| True within-pen prevalence | Chance the 20-fish sample includes a positive |
|---|---|
| 10% | ~86% |
| 5% | ~62% |
Turned around: with 20 fish and a perfect test, you can be 95% confident of picking up an infection only if at least ~14% of the pen is infected. Detecting 5% with the same confidence takes about 59 fish. This is the "freedom from disease" logic veterinary authorities use worldwide (Cannon & Roe, 1982, described in Kreienbrock & Schüpbach-Regula).
Two real-world complications:
- Pooling several fish into one PCR saves money but can cut sensitivity sharply, especially when viral loads are low (Muniesa et al., 2014).
- Imperfect specificity works the other way round. The more fish you test, the higher the chance that at least one is a false positive. That's one reason labs flag weak (high-Ct) positives for follow-up.
Lesson: a negative 0/20 PCR early in an outbreak means "below what this sample can detect", not "free". That's one reason a later test at the same site can come back positive without either result being wrong.
Apparent vs True Prevalence
When you count test positives, you get the apparent prevalence, which includes false positives and misses false negatives. In our 1,000-fish example, 124 of 1,000 fish tested positive: an apparent prevalence of 12.4%, against a true prevalence of 3%. That's about four times too high, from a test with 90% specificity.
If you know Se and Sp, you can correct for it. This is the Rogan–Gladen estimator:
True prevalence = (Apparent prevalence + Sp − 1) / (Se + Sp − 1)
which gives (0.124 + 0.9 − 1) / (0.9 + 0.9 − 1) = 3%.
Lesson: "X% of fish (or sites) tested positive this year" is not the same as "X% had the disease". Imperfect specificity inflates the count, especially when the disease is rare.
Fit for Purpose: No Test Is Good or Bad in General
The World Organisation for Animal Health (WOAH) judges diagnostic tests by whether they're fit for their intended purpose. The purposes include declaring a population free of disease, certifying animals for trade, supporting eradication, confirming clinical cases, estimating prevalence, and checking immune status after vaccination. Each purpose needs a different balance of Se and Sp. For example, confirming a clinical case calls for high specificity, to avoid false positives (Kreienbrock & Schüpbach-Regula).
For a fish health team, the practical version:
| You want to… | You need… | Example |
|---|---|---|
| Not miss an emerging problem | High sensitivity; accept false alarms | Early-warning signals, routine PCR screening, surveillance |
| Confirm before costly action | High specificity | Histopathology, cell culture, a vet's diagnosis combining clinical signs and lab results |
| Do both | Tests in series: a sensitive screen first, then a specific confirmation | Signal → sample → PCR → histopathology |
Testing in series trades a little sensitivity for a lot of specificity. A case only counts if it passes both tests. Using the PD test figures above, PCR followed by histopathology gives an overall specificity of about 99.5% and sensitivity of about 63%. That lifts the PPV at 3% prevalence from about 15% to about 79%. (This assumes the two tests' errors are independent of each other, which is a simplification.)
That's how the system is meant to work. An early-warning signal tells you where to look. The confirmatory test tells you what you found. Neither replaces the other.

Sensitivity and specificity, finally on speaking terms.
Cheat Sheet
| Term | Plain question | Formula | Depends on prevalence? |
|---|---|---|---|
| Sensitivity (recall) | Of the sick, how many does it catch? | TP / (TP + FN) | No* |
| Specificity | Of the healthy, how many does it clear? | TN / (TN + FP) | No* |
| PPV (precision) | It's positive. Is it real? | TP / (TP + FP) | Yes: falls as disease gets rarer |
| NPV | It's negative. Can I relax? | TN / (TN + FN) | Yes: rises as disease gets rarer |
| Accuracy | What share of all results are right? | (TP + TN) / total | Yes: inflated by true negatives when disease is rare |
| LR+ | How much does a positive raise the odds? | Se / (1 − Sp) | No* |
| Apparent prevalence | What share tested positive? | (TP + FP) / total | Yes |
| Group sensitivity | Will my sample of n catch an infected pen? | 1 − (1 − p·Se)n | Yes, on within-pen prevalence |
*For a fixed cut-off and a similar population. They can still vary with stage of infection, life stage and sampling.
Three habits to take away:
- Before reading any result, ask: how likely was this before I tested?
- Read positives for rare diseases as "look closer", and confirm before acting.
- Read a negative from a small sample as "not detected at this sample size", not "free".
Sources
- Kreienbrock L., Schüpbach-Regula G. Veterinary Epidemiology. In: Handbook of Epidemiology, Springer. See the sections "Application of Diagnostic Tests and Their Evaluation" (WOAH fit-for-purpose concept) and "Special Features in Field Studies" (freedom from disease; Cannon & Roe 1982; Cameron & Baldock 1998).
- Wright M.N. et al. Machine Learning in Epidemiology. In: Handbook of Epidemiology, Springer. See "Model Evaluation and Resampling → Evaluation Metrics" (PPV = precision, sensitivity = recall, threshold dependence).
- Jansen M.D. et al. (2019). Field evaluation of diagnostic test sensitivity and specificity for salmonid alphavirus (SAV) infection and pancreas disease (PD) in farmed Atlantic salmon in Norway using Bayesian latent class analysis. Frontiers in Veterinary Science. https://www.ncbi.nlm.nih.gov/pmc/articles/PMC6893554/
- Muniesa A. et al. (2014). Estimation of the relative sensitivity of qPCR analysis using pooled samples. PLOS ONE. https://www.ncbi.nlm.nih.gov/pmc/articles/PMC3983103/
- Dohoo I., Martin W., Stryhn H. (2009). Veterinary Epidemiologic Research, 2nd edn. VER Inc., Charlottetown. Chapter on screening and diagnostic tests.
- Rogan W.J., Gladen B. (1978). Estimating prevalence from the results of a screening test. American Journal of Epidemiology 107(1):71–76.
- Cannon R.M., Roe R.T. (1982). Livestock disease surveys: a field manual for veterinarians. Australian Bureau of Animal Health, Canberra.