# Thread: expected value in a beta dist.

1. ## expected value in a beta dist.

If X - Beta(p,q), derive E(X^n)

I'm having a hard time with the integration on this problem. Can anyone lead me through it?

Thanks.

2. ## Re: expected value in a beta dist.

Here's how i would approach this question:
$f(x|p,q) = \frac{1}{B(p,q)}x^{p-1}(1-x)^{q-1}$
So
$E[X^n]} = \frac{1}{B(p,q)} \int_0^1 x^{p-1+n}(1-x)^{q-1} dx$
$=\frac{B(p+n,q)}{B(p,q)} \int_0^1 \frac{x^{p-1+n}(1-x)^{q-1}}{B(p+n,q)} dx$
Can you finish?