Professional Documents
Culture Documents
CLT PDF
CLT PDF
http://ocw.mit.edu
For information about citing these materials or our Terms of Use, visit: http://ocw.mit.edu/terms.
Remember that last week, we saw the DeMoivre-Laplace theorem for Binomial random variables, which
essentially said that for large values of n, the standardization of the random variable Y B(n, p),
Z = Y E[Y ] follows approximately a standard normal distribution. Since a binomial is a sum of i.i.d.
nVar(Y )
zero/one random variables Xi (counting the number of trials resulting in a success), we can think of
Y
n as the sample mean of X1 , . . . , Xn .
Therefore the DeMoivre-Laplace theorem is in fact also a result on the standardized mean of i.i.d. zero/one
random variables. The Central Limit Theorem generalizes this to sample means of i.i.d. sequences from
any other distribution with nite variance.
Theorem 1 (Central Limit Theorem) Suppose X1 , . . . , Xn is a random sample of size n from a given
distribution with mean and variance 2 < . Then for any xed number x,
n
X
lim P
n
x = (x)
n
We say that nX
n converges in distribution (some people also say converges in law) to a normal with
mean and variance 2 , or in symbols:
d
n )
n(X
N (0, 2 )
So how does the mean converge both to a constant (according to the Law of Large Numbers), and
a random variable with variance one (according to the central limit theorem) at the same time? The
crucial detail here is that for the central limit theorem, we blow the sample mean up by a factor of n
which turns out to be exactly the right rate to keep the distribution from collapsing to a point (which
happens for the Law of Large Numbers) or exploding to innity.
Why is the standard normal distribution a plausible candidate for a limiting distribution of a sample
mean to start with? Remember that we argued that the sum of two independent normal random variables
again follows a normal distribution (though with a dierent variance, but since we only look at the
standardized mean, this doesnt matter), i.e. the normal family of distributions is stable with respect to
convolution (i.e. addition of independent random variables from the family). Note that this is not true
for most other distributions (e.g. the uniform or the exponential).
Since the sample mean is a weighted sum of the individual observations, increasing the sample from n to
2n, say, amounts to adding the mean of the sequence Xn+1 , . . . , X2n to the rst mean, and then dividing
n was not such that the sum
by 2. Therefore, if we postulated that even for large n, the distribution of X
1
.5
.8
Xbar_n
0
.6
Xbar_n
.5
.4
1.5
.2
0
0
100
200
300
400
500
100
200
300
400
500
1
if 0 x 1
fX (x) =
0
otherwise
We can now use the convolution formula from lecture 10 to compute the p.d.f. for the partial sums
Sk = X 1 + X 2 + . . . + Sk
For k = 2, we get (need to be careful about integration limits)
fS2 (s2 ) =
min{s2 ,1}
1dw
max{s2 1,0}
s2
2 s2
min{s2 , 1} max{s2 1, 0} =
if 0 s2 1
if 1 s2 2
otherwise
Now, the next calculations become more tedious because we always have to keep track of the integration
limits and the kink points in the density. After some calculations, I get for k = 3
s2
3
if 0 s3 1
23
2
+
3s
s
if
1 s3 2
3
3
2
fS2 (s3 w)fX (w)dw =
fS3 (s3 ) =
9
1 2
3s
+
s
if
2 s3 3
3
2 3
2
0
otherwise
E[Sk ] = kE[X1 ] =
k
2
Also, since X1 , X2 , . . . , Xk are independent, we can use the rule on the variance of the sum
Var(Sk )
1
1
1 1 1
k
t
= kVar(X1 ) = k
dt = k
=
+
2
3
2
4
12
0
k
2
k
12
12
formula (notice that the derivative is just equal to
k )
fZ1 (z)
1
12
1
6
1
6
z
6
z
6
if 3 z 3
otherwise
if 6 z 0
if 0 z 6
otherwise
fZ2 (z)
fZ3 (z)
0
1 3 z 2
4 2 + 2
3 z2
8 8
=
1 9
3
2 8 4z +
z2
8
if 3 z 1
if 1 z 1
if 1 z 3
otherwise
.1
density
.2
.3
.4
0
z
The p.d.f. for standardized sums of uniform random variables looks very similar to the standard
normal p.d.f. for a sum over as few as 3 independent draws - which is quite surprising since the uniform
density itself doesnt look at all like that of a normal random variable.
While the last example is a little deceptive in that the normal approximation looks quite good for n
as small as 3 (at least optically), with n , we usually mean n 40 or larger for the approximation
to be reasonably accurate.
Summarizing, the Central Limit Theorem is particularly useful when we dont want to compute the
true p.d.f. of the sample mean. There are two situations in which this happens
We cant compute the actual p.d.f. because we dont know the exact distribution of the Xi s
we dont want to compute the actual p.d.f. because the computations are too tedious - which is
almost invariably true for the general convolution formula (see last example), but also for many
discrete examples (see Binomial example from last lecture).
Estimation
So far in this class, we started by assuming that we knew the parameters of the distribution of a random
variable - e.g. we knew that X P () - and then calculated probabilities and other properties of random
samples from that distribution. Now we are going to look at the reverse problem:
Assume that we have an i.i.d. sample of observations from a distribution with unknown parameters ,
how do we get a reasonable answer which value of in the family of distributions we are looking at
Example 2 If for a given coin we dont know the probability for heads in a single toss, we could toss
Heads may be a good guess for the
it many times. Then wed think that the fraction of heads, p = Tosses
probability P (Heads) in a sense to be dened later.
A parameter is a constant indexing a family of distributions given by the p.d.f.s f (x|), where we denote
parameters generally as 1 , . . . , k .
Example 3
px (1 p)nx
x
fX (x|n, p) =
for x = 0, 1, . . . , n
otherwise
the parameters are the number of trials n and the success rate p.
for the normal distribution,
(x)2
1
e 22
2
so that parameters are mean and standard deviation
fX (x|, ) =
for x = 0, 1, 2, . . .
otherwise
Much of statistics is concerned with determining which member of a known family of distributions gives
the correct probability distribution of an observed process or phenomenon. In symbols, we want to nd
the parameter value 0 such that X f (x|0 ). This is the problem of estimating the parameters which
characterize the distribution.
Well always start o a random sample X1 , . . . , Xn , and well always assume that
X f (x|0 ) for unknown 0
4
if x = 1
0
1 0
if x = 0
fX (x) =
0
otherwise
How do we estimate 0 ?
Could use sample mean
1
(X1 , . . . , Xn ) =
Xi
n i=1
3
(1, 0, 0, 1, 1) =
5
05t (1 0 )5(1t)
if t 0, 15 , 52 , 35 , 45 , 1
5t
f(t) =
0
otherwise
In particular, the distribution of the estimator depends on the true probability 0 - which can be anywhere
in the interval [0,1] - but can only take 6 dierent discrete values.
Example 5 If X U [0, ] is uniform over an interval depending on the parameter, the p.d.f. is
1
if 0 x
fX (x) =
0
otherwise
How could we estimate ? Could use e.g.
1
2
= max{X1 , . . . , Xn }
n
= 2X
Say, we sampled three observations from the distribution, 0.2, 0.6, 0.4. Then 1 = 0.6 and 2 = 0.8, so
the two estimators give dierent answers on the same parameter. How should we choose among those
dierent estimators? - Well get back to this in a moment.
How do you come up with these functions (X1 , . . . , Xn )?
How can we determine whether these estimators are reasonable?
How should we choose between two or more estimators for the same parameter?
5
We will denote the expectation of X under the parameter - i.e. the expectation of X if the true
parameter is equal to - by
E [X] =
xfX (x|)dx
The bias of an estimator is the dierence between its expectation and the true parameter,
Bias() = E0 [] 0
Of course, wed like an estimator to get the parameter right on average, so that ideally, the bias should
be zero.
Denition 2 An estimator = (X1 , . . . , Xn ) is unbiased for if
E0 [] = 0
for all values of 0 .
Example 6 Suppose X1 , . . . , Xn is an i.i.d. sample from a N (, 2 ) distribution. We already saw last
week that the expectation of the sample mean
n ] = E,2 [X] =
E,2 [X
n is an unbiased estimator for the mean of a normal distribution.
for any value of , so that X
Example 7 Suppose we want to estimate the variance parameter 2 for X N (, 2 ) with unknown
mean from an i.i.d. random sample X1 , . . . , Xn . Since 2 = E[(X E[X])2 ], an intuitively appealing
estimator would be
n
1
)2
2 =
(Xi X
n i=1
(where we substituted the sample mean for the actual expectation). What is the expectation of this esti
mator if the true parameters of the distribution are (0 , 02 )?
Recall that E[X 2 ] = E[X]2 + Var(X), so that
n
1
+X
2)
E[
2 ] = E
(X 2 2Xi X
n i=1 i
n
1
2]
E[Xi2 X
n i=1
n
=
=
1
2]
E[Xi2 ] E[X
n i=1
n
1 2
1 2
2
2
( + ) +
n i=1
n
= 2 + 2 2
6
2
n1 2
=
n
n
Therefore
2 is not an unbiased estimator for 2 , but we can easily construct an unbiased estimator
2
n
2 =
1
n )2
(Xi X
n 1 i=1
Where does this bias come from? Broadly speaking, the reason is that inside the square we are replacing
n . You can check on your own that if 0 was known, the estimator
with
a (noisy) estimate
= X
n
1
2
2
In words, in a suciently large sample, a consistent estimator will be within a small distance from the
true parameter with high probability. Notice that unbiasedness and consistency are two very dierent
concepts which overlap, but neither implies the other:
Example 8 Back to one of our estimators for the uniform distribution, X U [0, 0 ]. If we look at
1 = max{X1 , . . . , Xn }
we can easily see that 1 is not unbiased for , because due to the nature of the uniform distribution, all
possible values of Xi are less than 0 . Therefore, no matter how large n is, P (max{X1 , . . . , Xn } < 0 ) = 1.
Therefore the expectation E0 [1 ] < 0 . However, 1 is consistent for 0 : We can easily see that for a
single observation X from the uniform, the c.d.f. is FX (x) = x0 . Since Yn := max{X1 , . . . , Xn } is the
nth order statistic
n of the sample, we get from our previous discussion that for 0 y 1, FYn (y) =
n
(FX (y)) = y . Since 1 < 0 with probability 1, we can therefore calculate for any sample size n
0
0
0
pn
where p := 0
< 1 since > 0. Therefore, the probability of a deviation from 0 by more than vanishes
0
as we increase n, and 1 is therefore consistent.
Example 9 By the Law of Large Numbers, the sample mean converges in probability to E[X] = .
Therefore, for an i.i.d. sample X1 , . . . , Xn of N (, 2 ) random variables, the sample mean is a consistent
estimator for .
E[(X1 , . . . , Xn )] = E[Xn ] =
7
so this estimator is unbiased. However, for any sample size n, the distribution of the estimator is the
same as that for Xi N (, ), so e.g. for = 0 , the probability
P (|(X1 , . . . , Xn ) 0 | < 0 )
= P (0 0 Xn 0 + 0 )
Xn 0
= P 1 <
< 1 = P (1 < Z < 1)
0
= (1) (1) 0.6825 << 1
Xn 0
0