$X$ is a Beta random variable with parameters $\alpha$, $\beta$. $Y$ is a binomial random variable with parameters $n$ and $p=x$ conditional on $X$. Find $P(Y = k)$.
I currently have $$P(Y = k) = \int_0^1 P(Y=k | X = x)f_X{(x)}\,dx = \int_{0}^{1}\binom{n}{k}x^{k}\left(1-x\right)^{n-k}\cdot\frac{\Gamma(\alpha + \beta)}{\Gamma(\alpha) \Gamma(\beta)}x^{\alpha - 1}(1-x)^{\beta - 1}dx.$$ I simplify this expression down to just $1$, using the fact that $\int_{0}^{1}x^{\alpha-1}\left(1-x\right)^{\beta-1}dx\ = \frac{\Gamma(\alpha)\Gamma(\beta)}{\Gamma(\alpha + \beta)}$. Am I correct?
Yes, the resulting integrand is still the kernel of a Beta thus
$$\mathbb{P}[Y=k]=\binom{n}{k}\frac{\Gamma(a+b)}{\Gamma(a)\Gamma(b)}\underbrace{\int_0^1x^{a+k-1}(1-x)^{n+b-k-1}dx}_{=\frac{\Gamma(a+k)\Gamma(n+b-k)}{\Gamma(a+b+n)}}$$
All the $\Gamma$ function can be simplified but I do not know if we can arrive at a nice formula...
I get
$$\binom{n}{k}\frac{\overbrace{a\cdot(a+1)\cdot(a+2)\cdot\dots\cdot(a+k-1)}^{\text{k-terms}}\cdot \overbrace{b\cdot(b+1)\cdot(b+2)\cdot\dots\cdot(b+n-k-1)}^{\text{(n-k) terms}}}{\underbrace{(a+b)\cdot(a+b+1)\cdot\dots\cdot(a+b+n-1)}_{\text{n-terms}}}=$$
$$=\binom{n}{k}\frac{\prod_{i=0}^{k-1}(a+i)\prod_{j=0}^{n-k+1}(b+j)}{\prod_{l=0}^{n-1}(a+b+l)}$$
I do not see how to further simplify it using binomial coefficients...perhaps it can be done but at the moment I am stuck