Discussion 12B

Markov Bound

If XX is nonnegative then Pr(Xa)E[X]a\Pr(X \geq a) \leq \frac{E[X]}{a}.

Proof 1

E[X]=xxPr(X=x)xaxPr(X=x)E[X] = \sum_x x \Pr(X=x) \geq \sum_{x \geq a} x \Pr(X=x)
xaaPr(X=x)=aPr(Xa)\geq \sum_{x\geq a} a \Pr(X=x) = a \Pr(X \geq a)

Proof 2

Let II be an indicator for the event XaX \geq a. Then aIXa I \leq X because 
  1. if XaX \geq a, then a1Xa \cdot 1 \leq X
  1. if X<aX < a, then a0Xa \cdot 0 \leq X
Taking the expectations of both sides gives us aE[I]E[X]a E[I] \leq E[X], or aPr(Xa)E[X]a \Pr(X \geq a) \leq E[X].

Chebyshev’s Inequality

For any random variable XX, let Y=(XE[X])2Y = (X - E[X])^2. Since YY is nonnegative we can apply the Markov Bound to YY, so Pr(Ya)E[Y]a\Pr(Y \geq a) \leq \frac{E[Y]}{a}, or similarly Pr(Ya2)E[Y]a2\Pr(Y \geq a^2) \leq \frac{E[Y]}{a^2}.
The LHS Pr(Ya2)=Pr((XE[X])2a2)=Pr(XE[X]a)\Pr(Y \geq a^2) = \Pr( (X-E[X])^2 \geq a^2) = \Pr( | X - E[X] | \geq a).
The RHS E[Y]a2=Var(X)a2\frac{E[Y]}{a^2} = \frac{\mathrm{Var}(X)}{a^2}.
Together, we get Pr(XE[X]a)Var(X)a2\Pr( | X - E[X] | \geq a) \leq \frac{\mathrm{Var}(X)}{a^2}.
With a substitution we get an alternate form Pr(XE[X]kσ)1k2\Pr( | X - E[X] | \geq k \sigma) \leq \frac{1}{k^2}.

Estimators

If there is some population parameter pp, an unbiased estimator p^\hat{p} is a measurement for which E[p^]=pE[\hat p] = p.

Iterated Expectation

E[XY]E[X \mid Y] is a conditional expectation. 
E[XY]=xxPr(X=xY)E[X \mid Y] = \sum_x x \Pr(X=x \mid Y)
It is a function of YY: for any particular value of Y=yY=y, what do we expect XX to be? So E[XY]=g(Y)E[X \mid Y] = g(Y).
The expectation of this function EY[g(Y)]=EY[E[XY]]=E[X]E_Y[g(Y)] = E_Y[ E[ X \mid Y ] ] = E[X].

This is also known as the law of total expectation because EY[g(Y)]=yg(y)Pr(Y=y)=yE[XY=y]Pr(Y=y)E_Y [g(Y)] = \sum_y g(y) \Pr(Y=y) = \sum_y E[X \mid Y=y] \Pr(Y=y).
Taking it a couple steps further,
yE[XY=y]Pr(Y=y)\sum_y E[X \mid Y=y] \Pr(Y=y)
=y(xxPr(X=xY=y))Pr(Y=y)= \sum_y \Big(\sum_x x \Pr(X=x \mid Y=y) \Big) \Pr(Y=y)
=x,yxPr(X=xY=y)Pr(Y=y)= \sum_{x,y} x \Pr(X=x \mid Y=y) \Pr(Y=y)
=x,yxPr(X=x,Y=y)= \sum_{x,y} x \Pr(X=x, Y=y)
=xxyPr(X=x,Y=y)= \sum_{x} x \sum_y \Pr(X=x, Y=y)
=xxPr(X=x)= \sum_x x \Pr(X=x)
=E[X]=E[X]