# Confidence interval for number of successes in population in a hypergeometric distribution

I have a hypergeometric distribution with known $N$, $n$ and $k$ (following the notation on Wikipedia) and I'd like to calculate the confidence interval for $K$.

I considered the Poisson approximation (but I'd like the confidence interval to be valid even for $K$ close to $N$).

What other options are there?

• A Bayesian interval won't give you an interval with the properties of a confidence interval (won't give you a selected level of coverage for example). If you're contemplating both credible intervals and confidence intervals at the same time, what properties are you looking for in an interval? What do you need this interval to actually do? – Glen_b Nov 7 '17 at 1:04
• I know about the difference between credible and confidence intervals, I just forgot to say explicitly that Bayes' theorem wouldn't output a confidence interval. I don't want this for any specific purpose, only that I realized I don't know how to calculate confidence interval for $K$ in this context and I'd like to learn how; there are no additional requirements for the interval. Also, the confidence interval is meant to be for $K$ (the number of objects with some desirable feature), not $k$ (the number of successes). – Golden Gleam Nov 7 '17 at 13:49
• On $K$: your question references the notation in the Wikipedia article; it defines $K$ there as the "number of success states in the population" while $k$ is the corresponding number in the sample. In this case "having some desirable feature" would be "success" – Glen_b Nov 7 '17 at 16:41
• OK, I understand. – Golden Gleam Nov 8 '17 at 13:50
• I removed the mention of Bayes' theorem to keep it about confidence intervals only. – Golden Gleam Nov 12 '17 at 17:03