Lecture 10 Improving Estimators: Rao–Blackwell and Lehmann–Scheffe

In lecture 8 we have seen that a sufficient statistic TT can be used to summarise all the information in the data about the parameter. In this lecture we will use this idea to construct improved versions of estimators. The Rao–Blackwell theorem states that conditioning an unbiased estimator on the value of TT never increases its variance. The Lehmann–Scheffe theorem states that, if TT is a complete sufficient statistic, this procedure gives the best unbiased estimator.

10.1 The Rao–Blackwell Theorem

Assume that we want to estimate a function g⁢(θ)g(\theta) of the parameter, e.g. we could be interested in the probability ℙθ⁢(X1=0)\mathbb{P}_{\theta}(X_{1}=0) of zero counts. As in lecture 2, an estimator UU with finite mean is unbiased for g⁢(θ)g(\theta), if 𝔼θ⁢(U)=g⁢(θ)\mathbb{E}_{\theta}(U)=g(\theta) for all θ∈Θ\theta\in\Theta. Unbiased estimators are often easy to find, but a crude one, such as the indicator of the event {X1=0}\{X_{1}=0\}, uses only a small part of the available sample. The Rao–Blackwell theorem uses a sufficient statistic TT to improve an existing estimator by replacing UU with the conditional expectation V=𝔼θ⁢(U|T)V=\mathbb{E}_{\theta}(U\mskip 1.0mu|\mskip 1.0muT), i.e. the average of UU for all samples which have the same value of TT as the observed sample.

Proposition 10.1 (Rao–Blackwell).

Let TT be a sufficient statistic for θ\theta and let UU be an unbiased estimator for g⁢(θ)g(\theta) with Varθ(U)<∞\mathop{\mathrm{Var}}\nolimits_{\theta}(U)<\infty for all θ\theta. Then V=𝔼θ⁢(U|T)V=\mathbb{E}_{\theta}(U\mskip 1.0mu|\mskip 1.0muT) has the following properties.

  1. 1.
    ​

    The random variable VV does not depend on θ\theta, but is a function of TT alone and thus a statistic.

  2. 2.
    ​

    The statistic VV is an unbiased estimator for g⁢(θ)g(\theta).

  3. 3.
    ​

    For all θ∈Θ\theta\in\Theta we have Varθ(V)≤Varθ(U)\mathop{\mathrm{Var}}\nolimits_{\theta}(V)\leq\mathop{\mathrm{Var}}\nolimits_{% \theta}(U).

Proof.

Since TT is a sufficient statistic, the conditional distribution of the sample (X1,…,Xn)(X_{1},\dots,X_{n}) given TT does not depend on θ\theta; for discrete data this is definition 8.1, and for continuous data it is the property stated after proposition 8.3. Since UU is a function of the sample, the conditional distribution of UU given TT, and thus the conditional expectation VV, do not depend on θ\theta either. Like every conditional expectation given TT, the random variable VV is a function of TT, as explained in appendix A, and since this function does not involve the parameter θ\theta, the random variable VV is a statistic in the sense of definition 1.3.

For the second statement, using the tower property from proposition A.9, we find

𝔼θ⁢(V)=𝔼θ⁢(𝔼θ⁢(U|T))=𝔼θ⁢(U)=g⁢(θ)\mathbb{E}_{\theta}(V)=\mathbb{E}_{\theta}\bigl{(}\mathbb{E}_{\theta}(U\mskip 1% .0mu|\mskip 1.0muT)\bigr{)}=\mathbb{E}_{\theta}(U)=g(\theta)

for all θ\theta. This shows that VV is unbiased.

Finally, for the third statement, we can use the law of total variance from proposition A.11, with UU instead of XX and TT instead of YY. Since 𝔼θ⁢(U|T)=V\mathbb{E}_{\theta}(U\mskip 1.0mu|\mskip 1.0muT)=V we get

Varθ(U)=𝔼θ⁢(Varθ(U|T))+Varθ(V).\mathop{\mathrm{Var}}\nolimits_{\theta}(U)=\mathbb{E}_{\theta}\bigl{(}\mathop{% \mathrm{Var}}\nolimits_{\theta}(U\mskip 1.0mu|\mskip 1.0muT)\bigr{)}+\mathop{% \mathrm{Var}}\nolimits_{\theta}(V).

Since the conditional variance is non-negative, as explained in appendix A, we get Varθ(V)≤Varθ(U)\mathop{\mathrm{Var}}\nolimits_{\theta}(V)\leq\mathop{\mathrm{Var}}\nolimits_{% \theta}(U). This completes the proof. ∎

Since both estimators are unbiased, their mean squared errors equal their variances by lemma 2.7, and thus VV is at least as good as UU. The procedure of passing from UU to VV is called Rao–Blackwellisation. Sufficiency is needed here: conditioning on a statistic which is not sufficient will in general give a quantity which depends on θ\theta and is thus not an estimator.

Example 10.2.

Let X1,…,XnX_{1},\dots,X_{n} be i.i.d. Poisson with parameter θ\theta and assume that we want to estimate g⁢(θ)=ℙθ⁢(X1=0)=e−θg(\theta)=\mathbb{P}_{\theta}(X_{1}=0)=e^{-\theta}. The indicator U=𝟏{X1=0}U=\mathbf{1}_{\{X_{1}=0\}} is unbiased for g⁢(θ)g(\theta), since 𝔼θ⁢(U)=ℙθ⁢(X1=0)\mathbb{E}_{\theta}(U)=\mathbb{P}_{\theta}(X_{1}=0). By corollary 8.5 the sum T=∑iXiT=\sum_{i}X_{i} is sufficient. Given T=tT=t, the first observation is distributed as Binomial⁢(t,1/n)\text{Binomial}(t,1/n); this is shown in exercise 10.1. Thus we have

V=𝔼θ⁢(U|T)=ℙθ⁢(X1=0|T)=(1−1n)T.V=\mathbb{E}_{\theta}(U\mskip 1.0mu|\mskip 1.0muT)=\mathbb{P}_{\theta}(X_{1}=0% \mskip 1.0mu|\mskip 1.0muT)=\Bigl{(}1-\frac{1}{n}\Bigr{)}^{T}.

The Rao–Blackwellised estimator now uses all nn observations. Exercise 10.3 applies the same procedure to a continuous model.

10.2 Completeness and the Lehmann–Scheffe Theorem

The Rao–Blackwell theorem improves an existing estimator, but two different unbiased estimators could in principle be improved to two different functions of TT. To rule this out we need one more property of a statistic, concerning functions of the statistic which are unbiased estimators for zero.

Definition 10.3.

A statistic TT is complete, if for every function ww such that w⁢(T)w(T) has finite mean under ℙθ\mathbb{P}_{\theta} for all θ∈Θ\theta\in\Theta, the condition 𝔼θ⁢(w⁢(T))=0\mathbb{E}_{\theta}\bigl{(}w(T)\bigr{)}=0 for all θ∈Θ\theta\in\Theta implies ℙθ⁢(w⁢(T)=0)=1\mathbb{P}_{\theta}\bigl{(}w(T)=0\bigr{)}=1 for all θ∈Θ\theta\in\Theta.

This means that a function of a complete statistic which has expectation zero for all parameter values is itself zero with probability one. The condition is violated for statistics which do not reduce the data enough: in exercise 10.2 we will see that the whole Bernoulli sample is sufficient, but not complete, whereas the total ∑iXi\sum_{i}X_{i} is complete by proposition 10.6 below. Completeness is a separate property from minimal sufficiency: a minimal sufficient statistic need not be complete. If TT is complete, two unbiased estimators for the same quantity which are both functions of TT agree with probability one, and thus every Rao–Blackwellisation leads to the same estimator. Before we prove this, we name the target.

Definition 10.4.

An unbiased estimator VV for g⁢(θ)g(\theta) with Varθ(V)<∞\mathop{\mathrm{Var}}\nolimits_{\theta}(V)<\infty for all θ∈Θ\theta\in\Theta is a uniformly minimum variance unbiased estimator (UMVUE) for g⁢(θ)g(\theta), if Varθ(V)≤Varθ(W)\mathop{\mathrm{Var}}\nolimits_{\theta}(V)\leq\mathop{\mathrm{Var}}\nolimits_{% \theta}(W) for all θ∈Θ\theta\in\Theta and for every unbiased estimator WW for g⁢(θ)g(\theta) with finite variance.

The word “uniformly” refers to the parameter: the inequality has to hold for every θ\theta at once, and there is no reason a priori why such an estimator should exist. The following theorem shows that, whenever a complete sufficient statistic exists, a UMVUE exists as well and is easy to identify.

Theorem 10.5 (Lehmann–Scheffe).

Let TT be a complete sufficient statistic for θ\theta and let V=φ⁢(T)V=\varphi(T) be a function of TT which is unbiased for g⁢(θ)g(\theta) and has Varθ(V)<∞\mathop{\mathrm{Var}}\nolimits_{\theta}(V)<\infty for all θ\theta. Then VV is a UMVUE for g⁢(θ)g(\theta).

Proof.

We first show that VV is the only unbiased estimator for g⁢(θ)g(\theta) among the functions of TT. Let ψ⁢(T)\psi(T) be another unbiased estimator for g⁢(θ)g(\theta) which is a function of TT. Then we have 𝔼θ⁢(ψ⁢(T))=g⁢(θ)=𝔼θ⁢(φ⁢(T))\mathbb{E}_{\theta}\bigl{(}\psi(T)\bigr{)}=g(\theta)=\mathbb{E}_{\theta}\bigl{% (}\varphi(T)\bigr{)} for all θ\theta. The function w=ψ−φw=\psi-\varphi satisfies 𝔼θ⁢(w⁢(T))=0\mathbb{E}_{\theta}\bigl{(}w(T)\bigr{)}=0 for all θ\theta and, since TT is complete, by definition 10.3, we have ℙθ⁢(w⁢(T)=0)=1\mathbb{P}_{\theta}\bigl{(}w(T)=0\bigr{)}=1 for all θ\theta, i.e. ψ⁢(T)=φ⁢(T)\psi(T)=\varphi(T) with probability one.

Now let WW be any unbiased estimator for g⁢(θ)g(\theta) with finite variance. Then, by the Rao–Blackwell theorem, proposition 10.1, the random variable 𝔼θ⁢(W|T)\mathbb{E}_{\theta}(W\mskip 1.0mu|\mskip 1.0muT) is a function of TT which is unbiased for g⁢(θ)g(\theta). Thus, by the first step of the proof, it equals VV with probability one. The Rao–Blackwell theorem then gives

Varθ(V)=Varθ(𝔼θ⁢(W|T))≤Varθ(W)\mathop{\mathrm{Var}}\nolimits_{\theta}(V)=\mathop{\mathrm{Var}}\nolimits_{% \theta}\bigl{(}\mathbb{E}_{\theta}(W\mskip 1.0mu|\mskip 1.0muT)\bigr{)}\leq% \mathop{\mathrm{Var}}\nolimits_{\theta}(W)

for all θ\theta, i.e. VV is a UMVUE. This completes the proof. ∎

The theorem turns the search for a best unbiased estimator into a two-step recipe: find a complete sufficient statistic TT, then find any function of TT which is unbiased for g⁢(θ)g(\theta), by adjusting a constant or by Rao–Blackwellising a crude unbiased estimator. For the models of this module the following two facts settle the question of completeness.

Proposition 10.6.
  1. 1.
    ​

    Let X1,…,XnX_{1},\dots,X_{n} be an i.i.d. sample from a one-parameter exponential family of full rank, as given in definitions 7.1 and 7.8. Then the natural statistic Tn=∑i=1nT⁢(Xi)T_{n}=\sum_{i=1}^{n}T(X_{i}) of the sample is complete. For a kk-parameter exponential family of full rank, as given in definition 7.6, the vector

    (∑i=1nT1⁢(Xi),…,∑i=1nTk⁢(Xi))\Bigl{(}\sum_{i=1}^{n}T_{1}(X_{i}),\dots,\sum_{i=1}^{n}T_{k}(X_{i})\Bigr{)}

    of summed natural statistics is complete.

  2. 2.
    ​

    Let X1,…,XnX_{1},\dots,X_{n} be i.i.d. and uniformly distributed on the interval [0,θ][0,\theta] where θ>0\theta>0. Then the sample maximum maxi⁡Xi\max_{i}X_{i} is complete.

We state this proposition without proof, and both statements may be used without proof in what follows. The first statement rests on the uniqueness theorem for Laplace transforms. The second statement rests on taking derivatives, with respect to θ\theta, of the relation ∫0θw⁢(t)⁢tn−1⁢dt=0\int_{0}^{\theta}w(t)\,t^{n-1}\,\mathrm{d}t=0, which is the condition 𝔼θ⁢(w⁢(maxi⁡Xi))=0\mathbb{E}_{\theta}\bigl{(}w(\max_{i}X_{i})\bigr{)}=0 up to a constant factor. Together with corollary 8.5 and example 8.4 they provide a complete sufficient statistic for every family in tables 1.1 and 1.2 (with mm known for the binomial). A one-to-one function φ⁢(T)\varphi(T) of a complete sufficient statistic TT is again complete and sufficient: sufficiency was shown in lecture 8, and if 𝔼θ⁢(w⁢(φ⁢(T)))=0\mathbb{E}_{\theta}\bigl{(}w(\varphi(T))\bigr{)}=0 for all θ\theta, then w∘φw\circ\varphi is a function of TT with mean zero and thus, since TT is complete, w⁢(φ⁢(T))=0w\bigl{(}\varphi(T)\bigr{)}=0 with probability one. In particular, we can use the sample mean X¯\bar{X} instead of ∑iXi\sum_{i}X_{i} if required.

Example 10.7.

For the Poisson sample from example 10.2, the natural parameter η=log⁡θ\eta=\log\theta takes values on all of ℝ\mathbb{R}, and thus the family is of full rank in the sense of definition 7.8. By corollary 8.5 and proposition 10.6 the sum T=∑iXiT=\sum_{i}X_{i} is a complete and sufficient statistic. Since X¯=T/n\bar{X}=T/n is a function of TT, is unbiased for θ\theta and has finite variance θ/n\theta/n, it is the UMVUE for θ\theta by theorem 10.5. Similarly, the Rao–Blackwellised indicator V=(1−1/n)TV=(1-1/n)^{T} takes values in [0,1][0,1] and thus has finite variance, and it is the UMVUE for e−θe^{-\theta}.

Example 10.8.

Let X1,…,XnX_{1},\dots,X_{n} be i.i.d. N⁢(μ,σ2)N(\mu,\sigma^{2}) with both parameters unknown. This is a two-parameter exponential family with natural statistic T⁢(x)=(x,x2)T(x)=(x,x^{2}), and the pair (X¯,S2)(\bar{X},S^{2}) is sufficient by example 8.7. The family has full rank, and thus the pair is also complete by proposition 10.6; exercise 10.5 verifies the rank condition. Since X¯\bar{X} and S2S^{2} are unbiased for μ\mu and σ2\sigma^{2} by lemmas 2.2 and 2.3, they are the UMVUEs for these parameters.

The second example puts section 2.3 into perspective: there the biased estimator 1n+1⁢∑i(Xi−X¯)2\frac{1}{n+1}\sum_{i}(X_{i}-\bar{X})^{2} had smaller mean squared error than S2S^{2}. This is no contradiction, since the Lehmann–Scheffe theorem compares S2S^{2} to unbiased estimators only.

In lecture 13 we will see a second way to derive optimality, using the Cramer–Rao bound, which does not require conditioning.

Summary.
  • •
    ​

    Rao–Blackwell: If an unbiased estimator is conditioned on a sufficient statistic TT, the conditioned estimator is unbiased and has no larger variance.

  • •
    ​

    A UMVUE is an unbiased estimator which has minimal variance among all unbiased estimators, for all θ\theta.

  • •
    ​

    A statistic TT is complete, if every function of TT with expectation zero for all θ\theta is zero with probability one.

  • •
    ​

    Lehmann–Scheffe: If TT is complete and sufficient, then the only function of TT which is unbiased for g⁢(θ)g(\theta) is the UMVUE for g⁢(θ)g(\theta).

  • •
    ​

    The natural statistic for a full-rank exponential family and the maximum of a uniform sample are complete (stated without proof).

Exercise 10.1.

Let n≥2n\geq 2, let X1,…,XnX_{1},\dots,X_{n} be i.i.d. Poisson with parameter θ>0\theta>0, let T=∑i=1nXiT=\sum_{i=1}^{n}X_{i} and let U=𝟏{X1=0}U=\mathbf{1}_{\{X_{1}=0\}}, as in example 10.2. You may use the fact that a sum of independent Poisson random variables is again Poisson, with the parameters added.

  1. 1.
    ​

    Show that UU is an unbiased estimator for e−θe^{-\theta} and determine the variance of this estimator.

  2. 2.
    ​

    Show that for t∈ℕ0t\in\mathbb{N}_{0} and x∈{0,1,…,t}x\in\{0,1,\dots,t\} we have

    ℙθ⁢(X1=x|T=t)=(tx)⁢(1n)x⁢(1−1n)t−x,\mathbb{P}_{\theta}(X_{1}=x\mskip 1.0mu|\mskip 1.0muT=t)=\binom{t}{x}\Bigl{(}% \frac{1}{n}\Bigr{)}^{x}\Bigl{(}1-\frac{1}{n}\Bigr{)}^{t-x},

    i.e. that the conditional distribution of X1X_{1} given T=tT=t is Binomial⁢(t,1/n)\text{Binomial}(t,1/n) and that this distribution does not depend on θ\theta.

  3. 3.
    ​

    Deduce that V=𝔼θ⁢(U|T)=(1−1/n)TV=\mathbb{E}_{\theta}(U\mskip 1.0mu|\mskip 1.0muT)=(1-1/n)^{T}.

  4. 4.
    ​

    Show directly that VV is an unbiased estimator for e−θe^{-\theta}, using the probability generating function (7.3) of the Poisson distribution with parameter n⁢θn\theta, which is given by 𝔼θ⁢(zT)=exp⁡(n⁢θ⁢(z−1))\mathbb{E}_{\theta}(z^{T})=\exp\bigl{(}n\theta(z-1)\bigr{)} (exercise 7.6).

  5. 5.
    ​

    Explain why VV is the UMVUE for e−θe^{-\theta} and discuss the differences between this UMVUE and the MLE e−X¯e^{-\bar{X}}, introduced in exercise 5.7.

Exercise 10.2.

Let X1,…,XnX_{1},\dots,X_{n} be i.i.d. Bernoulli with success probability θ∈(0,1)\theta\in(0,1), where n≥2n\geq 2, and let T=(X1,…,Xn)T=(X_{1},\dots,X_{n}) be the whole sample.

  1. 1.
    ​

    Show that w⁢(T)=X1−X2w(T)=X_{1}-X_{2} satisfies 𝔼θ⁢(w⁢(T))=0\mathbb{E}_{\theta}\bigl{(}w(T)\bigr{)}=0 for all θ\theta and ℙθ⁢(w⁢(T)=0)<1\mathbb{P}_{\theta}\bigl{(}w(T)=0\bigr{)}<1.

  2. 2.
    ​

    Using definition 10.3, show that TT is not complete, despite TT being sufficient.

Exercise 10.3.

Let n≥2n\geq 2 and let X1,…,XnX_{1},\dots,X_{n} be i.i.d. exponential with rate θ>0\theta>0, i.e. f⁢(x;θ)=θ⁢e−θ⁢xf(x;\theta)=\theta e^{-\theta x} for x≥0x\geq 0 and let T=∑i=1nXiT=\sum_{i=1}^{n}X_{i}. You may use the fact that the sum of kk independent random variables of this type has density fk⁢(t)=θk⁢tk−1⁢e−θ⁢t/(k−1)!f_{k}(t)=\theta^{k}t^{k-1}e^{-\theta t}/(k-1)! for t≥0t\geq 0.

  1. 1.
    ​

    Explain why X1X_{1} is an unbiased estimator for the mean 1/θ1/\theta and why TT is sufficient for θ\theta.

  2. 2.
    ​

    Let R=∑i=2nXiR=\sum_{i=2}^{n}X_{i}. Use the independence of X1X_{1} and RR to find the joint density of (X1,T)(X_{1},T). Deduce the conditional density of X1X_{1} given T=sT=s. The result is

    f⁢(x|s)=(n−1)⁢(s−x)n−2sn−1for ⁢0<x<s,f(x\mskip 1.0mu|\mskip 1.0mus)=\frac{(n-1)(s-x)^{n-2}}{s^{n-1}}\qquad\text{for% }0<x<s,

    and zero elsewhere. Check that this density does not depend on θ\theta.

  3. 3.
    ​

    Show that 𝔼θ⁢(X1|T=s)=s/n\mathbb{E}_{\theta}(X_{1}\mskip 1.0mu|\mskip 1.0muT=s)=s/n and conclude that Rao–Blackwellising X1X_{1} leads to the sample mean X¯\bar{X}, again unbiased for 1/θ1/\theta.

  4. 4.
    ​

    Find a second argument for 𝔼θ⁢(X1|T)=T/n\mathbb{E}_{\theta}(X_{1}\mskip 1.0mu|\mskip 1.0muT)=T/n, based on the symmetry of the sample, without any integration.

Exercise 10.4.

Let X1,…,XnX_{1},\dots,X_{n} be i.i.d. uniformly distributed on the interval [0,θ][0,\theta] where θ>0\theta>0, and let M=maxi⁡XiM=\max_{i}X_{i}.

  1. 1.
    ​

    Using the mean of MM from exercise 2.2, show that θ^=(n+1)⁢M/n\hat{\theta}=(n+1)M/n is an unbiased estimator for θ\theta.

  2. 2.
    ​

    Show that θ^\hat{\theta} is the UMVUE for θ\theta.

  3. 3.
    ​

    The estimator θ~=2⁢X¯\tilde{\theta}=2\bar{X} is also unbiased for θ\theta. Determine the variances of θ^\hat{\theta} and of θ~\tilde{\theta} and verify that they are ordered as in theorem 10.5.

  4. 4.
    ​

    Without computing any conditional expectations, find 𝔼θ⁢(θ~|M)\mathbb{E}_{\theta}(\tilde{\theta}\mskip 1.0mu|\mskip 1.0muM).

Exercise 10.5.

Let X1,…,XnX_{1},\dots,X_{n} be i.i.d. N⁢(μ,σ2)N(\mu,\sigma^{2}), where both parameters are unknown. This is the situation of example 10.8.

  1. 1.
    ​

    Write the density of an observation in the form from definition 7.6, confirm that the natural statistic is T⁢(x)=(x,x2)T(x)=(x,x^{2}) and determine the natural parameter η⁢(μ,σ2)\eta(\mu,\sigma^{2}) and the function B⁢(μ,σ2)B(\mu,\sigma^{2}).

  2. 2.
    ​

    Show that the family of densities has full rank, in the sense of definition 7.8, by determining the range of η\eta.

  3. 3.
    ​

    Deduce that (∑iXi,∑iXi2)\bigl{(}\sum_{i}X_{i},\sum_{i}X_{i}^{2}\bigr{)} is complete and sufficient and argue that the same holds for the pair (X¯,S2)(\bar{X},S^{2}).