# Show that the statistics $T(X_1,\ldots,X_n)=(X_{(1)},X_{(n)})$ is a sufficient statistics for $\theta$

Let $$X_1,\ldots,X_n$$ be a random sample from $$U(\theta-\frac{1}{2},\theta+\frac{1}{2})$$. Show that the statistics $$T(X_1,\ldots,X_n)=(X_{(1)},X_{(n)})$$ is a sufficient statistics for $$\theta$$.

Can someone show me how to use the theorem below in proving the above question:

Theorem If $$p(x|\theta)$$ is the joint pdf or pmf of $$X$$ and $$q(t|\theta)$$ is the pdf or pmf of $$T(X)$$, then $$T(X)$$ is a sufficient statistic for $$\theta$$ if, for every $$x$$ in the sample space, the ratio $$\frac{p(x|\theta)}{q(T(x)|\theta)}$$ is a constant as a function of $$\theta$$.

• What's wrong with using Factorization theorem? $$f_{\theta}(x_1,\ldots,x_n)=\mathbf1_{\theta-1/2<x_{(1)},x_{(n)}<\theta+1/2}=\mathbf1_{x_{(n)}-1/2<\theta<x_{(1)}+1/2}\quad,\,\theta\in\mathbb R$$ – StubbornAtom Feb 5 at 20:30
• @StubbornAtom, there is absolutely nothing wrong. I just want to see if the above can also be used in proving. – Lady Feb 5 at 20:34