counted_prevalence function

Count prevalence from registry data.