[Math] Computing the UMVUE for Uniform$(0,\theta)$

probability theorystatistics

I am having trouble understanding how to compute $\operatorname E[\bar{X}\mid X_{(n)}]$ related to the following premise.

Compute the UMVUE using the Rao–Blackwell Theorem for the following.
$X_1,X_2, \ldots ,X_n$ i.i.d. to $\operatorname{Uniform}(0,\theta)$.

I am able to derive that $\hat{\theta}_\text{MM}=2\bar{X}$ and $\hat{\theta}_\text{MLE}=X_{(n)}$.

Since $\hat{\theta}_\text{MM}$ is unbiased and $X_{(n)}$ is a sufficient estimator, I know that $$\operatorname E[2\bar{X}\mid X_{(n)}]$$ must give us the UMVUE.

However, I have no idea how to proceed from here.
I appreciate your help.

Best Answer

We use the fact that, conditional on the max, the lower order statistics are distributed like the order statistics of iid $U(0,X_{(n)}).$ So, conditional on $X_{(n)}$ $$\bar X \sim \frac{X_{(n)} + \sum_{i=1}^{n-1}U_i}{n}$$ where the $U_i$ are i.i.d. $U(0,X_{(n)}).$ Then we have $$ E(\bar X\mid X_{(n)}) = \frac{X_{(n)}+\frac{n-1}{2}X_{(n)}}{n} = \frac{(n+1)}{2n}X_{(n)}.$$

(We could have also derived this by the "what else could it possibly be?" method. It needs to be unbiased, a statistic, and a dimensionally sensible function of $X_{(n)}$... there's only one game in town here.)