Appendix A. General formula for corrected prevalence.
In many cases, it will be possible to partition sources of heterogeneity in detection probabilities into one or more discrete classes of individuals. For example, consider a situation where detection probabilities vary as a function of gender, age, and health status. Incorporating class specific detection probabilities, we can calculate a corrected estimate of prevalence as

where,
= corrected disease prevalence at time i,
= observed count of focal species in health state j (I: infected or U: uninfected), gender k, and age l (up to a age classes) at time i,
= the estimated detection probability of focal species in health state j, gender k, and age l at time i,
= the estimated detection probability of focal species in health state x, gender y, and age z (up to a age classes) at time i.
Extending the expression for additional states is straightforward.