The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe...

39
The Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006 Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 1 / 13

Transcript of The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe...

Page 1: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

The Neyman-Pearson LemmaMathematics 47: Lecture 28

Dan Sloughter

Furman University

April 26, 2006

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 1 / 13

Page 2: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Theorem (The Neyman-Pearson Lemma)

I Let X1, X2, . . . , Xn be random variables with joint probabilityfunction f (x1, x2, . . . , xn).

I Suppose we wish to test H0 : f = f0 versus HA : f = f1, where f0 andf1 are completely specified probability functions.

I Let Λ =f0(X1,X2, . . . ,Xn)

f1(X1,X2, . . . ,Xn).

I For a fixed k > 0, let α = P(Λ ≤ k | H0) and

C = {(x1, x2, . . . , xn) ∈ Rn : Λ(x1, x2, . . . , xn) ≤ k}

I If C ∗ is any other subset of Rn for which

P((X1,X2, . . . ,Xn) ∈ C ∗ | H0) ≤ α,

then

P((X1,X2, . . . ,Xn) ∈ C ∗ | HA) ≤ P((X1,X2, . . . ,Xn) ∈ C | HA).

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 2 / 13

Page 3: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Theorem (The Neyman-Pearson Lemma)

I Let X1, X2, . . . , Xn be random variables with joint probabilityfunction f (x1, x2, . . . , xn).

I Suppose we wish to test H0 : f = f0 versus HA : f = f1, where f0 andf1 are completely specified probability functions.

I Let Λ =f0(X1,X2, . . . ,Xn)

f1(X1,X2, . . . ,Xn).

I For a fixed k > 0, let α = P(Λ ≤ k | H0) and

C = {(x1, x2, . . . , xn) ∈ Rn : Λ(x1, x2, . . . , xn) ≤ k}

I If C ∗ is any other subset of Rn for which

P((X1,X2, . . . ,Xn) ∈ C ∗ | H0) ≤ α,

then

P((X1,X2, . . . ,Xn) ∈ C ∗ | HA) ≤ P((X1,X2, . . . ,Xn) ∈ C | HA).

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 2 / 13

Page 4: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Theorem (The Neyman-Pearson Lemma)

I Let X1, X2, . . . , Xn be random variables with joint probabilityfunction f (x1, x2, . . . , xn).

I Suppose we wish to test H0 : f = f0 versus HA : f = f1, where f0 andf1 are completely specified probability functions.

I Let Λ =f0(X1,X2, . . . ,Xn)

f1(X1,X2, . . . ,Xn).

I For a fixed k > 0, let α = P(Λ ≤ k | H0) and

C = {(x1, x2, . . . , xn) ∈ Rn : Λ(x1, x2, . . . , xn) ≤ k}

I If C ∗ is any other subset of Rn for which

P((X1,X2, . . . ,Xn) ∈ C ∗ | H0) ≤ α,

then

P((X1,X2, . . . ,Xn) ∈ C ∗ | HA) ≤ P((X1,X2, . . . ,Xn) ∈ C | HA).

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 2 / 13

Page 5: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Theorem (The Neyman-Pearson Lemma)

I Let X1, X2, . . . , Xn be random variables with joint probabilityfunction f (x1, x2, . . . , xn).

I Suppose we wish to test H0 : f = f0 versus HA : f = f1, where f0 andf1 are completely specified probability functions.

I Let Λ =f0(X1,X2, . . . ,Xn)

f1(X1,X2, . . . ,Xn).

I For a fixed k > 0, let α = P(Λ ≤ k | H0) and

C = {(x1, x2, . . . , xn) ∈ Rn : Λ(x1, x2, . . . , xn) ≤ k}

I If C ∗ is any other subset of Rn for which

P((X1,X2, . . . ,Xn) ∈ C ∗ | H0) ≤ α,

then

P((X1,X2, . . . ,Xn) ∈ C ∗ | HA) ≤ P((X1,X2, . . . ,Xn) ∈ C | HA).

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 2 / 13

Page 6: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Theorem (The Neyman-Pearson Lemma)

I Let X1, X2, . . . , Xn be random variables with joint probabilityfunction f (x1, x2, . . . , xn).

I Suppose we wish to test H0 : f = f0 versus HA : f = f1, where f0 andf1 are completely specified probability functions.

I Let Λ =f0(X1,X2, . . . ,Xn)

f1(X1,X2, . . . ,Xn).

I For a fixed k > 0, let α = P(Λ ≤ k | H0) and

C = {(x1, x2, . . . , xn) ∈ Rn : Λ(x1, x2, . . . , xn) ≤ k}

I If C ∗ is any other subset of Rn for which

P((X1,X2, . . . ,Xn) ∈ C ∗ | H0) ≤ α,

then

P((X1,X2, . . . ,Xn) ∈ C ∗ | HA) ≤ P((X1,X2, . . . ,Xn) ∈ C | HA).

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 2 / 13

Page 7: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Theorem (The Neyman-Pearson Lemma)

I Let X1, X2, . . . , Xn be random variables with joint probabilityfunction f (x1, x2, . . . , xn).

I Suppose we wish to test H0 : f = f0 versus HA : f = f1, where f0 andf1 are completely specified probability functions.

I Let Λ =f0(X1,X2, . . . ,Xn)

f1(X1,X2, . . . ,Xn).

I For a fixed k > 0, let α = P(Λ ≤ k | H0) and

C = {(x1, x2, . . . , xn) ∈ Rn : Λ(x1, x2, . . . , xn) ≤ k}

I If C ∗ is any other subset of Rn for which

P((X1,X2, . . . ,Xn) ∈ C ∗ | H0) ≤ α,

then

P((X1,X2, . . . ,Xn) ∈ C ∗ | HA) ≤ P((X1,X2, . . . ,Xn) ∈ C | HA).

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 2 / 13

Page 8: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Notes on the Neyman-Pearson Lemma

I Note:

α = P(Λ ≤ k | H0)

= P((X1,X2, . . . ,Xn) ∈ C | H0)

=

∫· · ·

∫C

f0(x1, . . . , xn)dx1 · · · dxn.

I The lemma says: among all tests with significance level less than orequal to α, the test with critical region C has the largest power.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 3 / 13

Page 9: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Notes on the Neyman-Pearson Lemma

I Note:

α = P(Λ ≤ k | H0)

= P((X1,X2, . . . ,Xn) ∈ C | H0)

=

∫· · ·

∫C

f0(x1, . . . , xn)dx1 · · · dxn.

I The lemma says: among all tests with significance level less than orequal to α, the test with critical region C has the largest power.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 3 / 13

Page 10: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Proof.

I Letα∗ = P((X1,X2, . . . ,Xn) ∈ C ∗ | H0).

I Then

P((X1,X2, . . . ,Xn) ∈ C | HA)− P((X1,X2, . . . ,Xn) ∈ C ∗ | HA)

=

∫· · ·

∫C

f1(x1, . . . , xn)dx1 · · · dxn

−∫

· · ·∫

C∗f1(x1, . . . , xn)dx1 · · · dxn

=

∫· · ·

∫C∩(Rn−C∗)

f1(x1, . . . , xn)dx1 · · · dxn

−∫

· · ·∫

C∗∩(Rn−C)f1(x1, . . . , xn)dx1 · · · dxn.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 4 / 13

Page 11: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Proof.I Let

α∗ = P((X1,X2, . . . ,Xn) ∈ C ∗ | H0).

I Then

P((X1,X2, . . . ,Xn) ∈ C | HA)− P((X1,X2, . . . ,Xn) ∈ C ∗ | HA)

=

∫· · ·

∫C

f1(x1, . . . , xn)dx1 · · · dxn

−∫

· · ·∫

C∗f1(x1, . . . , xn)dx1 · · · dxn

=

∫· · ·

∫C∩(Rn−C∗)

f1(x1, . . . , xn)dx1 · · · dxn

−∫

· · ·∫

C∗∩(Rn−C)f1(x1, . . . , xn)dx1 · · · dxn.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 4 / 13

Page 12: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Proof.I Let

α∗ = P((X1,X2, . . . ,Xn) ∈ C ∗ | H0).

I Then

P((X1,X2, . . . ,Xn) ∈ C | HA)− P((X1,X2, . . . ,Xn) ∈ C ∗ | HA)

=

∫· · ·

∫C

f1(x1, . . . , xn)dx1 · · · dxn

−∫

· · ·∫

C∗f1(x1, . . . , xn)dx1 · · · dxn

=

∫· · ·

∫C∩(Rn−C∗)

f1(x1, . . . , xn)dx1 · · · dxn

−∫

· · ·∫

C∗∩(Rn−C)f1(x1, . . . , xn)dx1 · · · dxn.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 4 / 13

Page 13: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Proof.

I And so

P((X1,X2, . . . ,Xn) ∈ C | HA)− P((X1,X2, . . . ,Xn) ∈ C ∗ | HA)

≥ 1

k

∫· · ·

∫C∩(Rn−C∗)

f0(x1, . . . , xn)dxn · · · dxn

− 1

k

∫· · ·

∫C∗∩(Rn−C)

f0(x1, · · · , xn)dx1 · · · dxn

=1

k

( ∫· · ·

∫C

f0(x1, . . . , xn)dx1 · · · dxn

−∫

· · ·∫

C∗f0(x1, . . . , xn)dx1 · · · dxn

)=

1

k(α− α∗)

≥ 0.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 5 / 13

Page 14: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Proof.I And so

P((X1,X2, . . . ,Xn) ∈ C | HA)− P((X1,X2, . . . ,Xn) ∈ C ∗ | HA)

≥ 1

k

∫· · ·

∫C∩(Rn−C∗)

f0(x1, . . . , xn)dxn · · · dxn

− 1

k

∫· · ·

∫C∗∩(Rn−C)

f0(x1, · · · , xn)dx1 · · · dxn

=1

k

( ∫· · ·

∫C

f0(x1, . . . , xn)dx1 · · · dxn

−∫

· · ·∫

C∗f0(x1, . . . , xn)dx1 · · · dxn

)=

1

k(α− α∗)

≥ 0.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 5 / 13

Page 15: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Testing a parameter

I Note: If X1, X2, . . . , Xn is a random sample from a distribution withparameter θ and we wish to test

H0 : θ = θ0

HA : θ = θ1,

then

Λ =L(θ0)

L(θ1),

where L is the likelihood function.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 6 / 13

Page 16: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Example

I Let X1, X2, . . . , Xn be a random sample from a Bernoulli distributionwith probability of success p.

I Suppose we wish to test

H0 : p = p0

HA : p = p1.

I Let T = X1 + X2 + · · ·+ Xn.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 7 / 13

Page 17: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Example

I Let X1, X2, . . . , Xn be a random sample from a Bernoulli distributionwith probability of success p.

I Suppose we wish to test

H0 : p = p0

HA : p = p1.

I Let T = X1 + X2 + · · ·+ Xn.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 7 / 13

Page 18: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Example

I Let X1, X2, . . . , Xn be a random sample from a Bernoulli distributionwith probability of success p.

I Suppose we wish to test

H0 : p = p0

HA : p = p1.

I Let T = X1 + X2 + · · ·+ Xn.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 7 / 13

Page 19: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Example

I Let X1, X2, . . . , Xn be a random sample from a Bernoulli distributionwith probability of success p.

I Suppose we wish to test

H0 : p = p0

HA : p = p1.

I Let T = X1 + X2 + · · ·+ Xn.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 7 / 13

Page 20: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Example (cont’d)

I Then

Λ =L(p0)

L(p1)

=

∏ni=1 pXi

0 (1− p0)1−Xi∏n

i=1 pXi1 (1− p1)1−Xi

=p

Pni=1 Xi

0 (1− p0)n−

Pni=1 Xi

pPn

i=1 Xi

1 (1− p1)n−Pn

i=1 Xi

=pT0 (1− p0)

n−T

pT1 (1− p1)n−T

=

(p0

p1

)T (1− p0

1− p1

)n−T

=

(1− p0

1− p1

)n (p0(1− p1)

p1(1− p0)

)T

.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 8 / 13

Page 21: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Example (cont’d)

I Then

Λ =L(p0)

L(p1)

=

∏ni=1 pXi

0 (1− p0)1−Xi∏n

i=1 pXi1 (1− p1)1−Xi

=p

Pni=1 Xi

0 (1− p0)n−

Pni=1 Xi

pPn

i=1 Xi

1 (1− p1)n−Pn

i=1 Xi

=pT0 (1− p0)

n−T

pT1 (1− p1)n−T

=

(p0

p1

)T (1− p0

1− p1

)n−T

=

(1− p0

1− p1

)n (p0(1− p1)

p1(1− p0)

)T

.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 8 / 13

Page 22: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Example (cont’d)

I Now if p0 < p1, then 1− p0 > 1− p1, and so

0 <p0(1− p1)

p1(1− p0)< 1.

I If p0 > p1, the 1− p0 < 1− p1, and so

p0(1− p1)

p1(1− p0)> 1.

I Hence when p0 < p1, the condition Λ ≤ k is equivalent to thecondition T ≥ k∗ for some k∗.

I When p0 > p1, the condition Λ ≤ k is equivalent to T ≤ k∗ for somek∗.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 9 / 13

Page 23: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Example (cont’d)

I Now if p0 < p1, then 1− p0 > 1− p1, and so

0 <p0(1− p1)

p1(1− p0)< 1.

I If p0 > p1, the 1− p0 < 1− p1, and so

p0(1− p1)

p1(1− p0)> 1.

I Hence when p0 < p1, the condition Λ ≤ k is equivalent to thecondition T ≥ k∗ for some k∗.

I When p0 > p1, the condition Λ ≤ k is equivalent to T ≤ k∗ for somek∗.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 9 / 13

Page 24: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Example (cont’d)

I Now if p0 < p1, then 1− p0 > 1− p1, and so

0 <p0(1− p1)

p1(1− p0)< 1.

I If p0 > p1, the 1− p0 < 1− p1, and so

p0(1− p1)

p1(1− p0)> 1.

I Hence when p0 < p1, the condition Λ ≤ k is equivalent to thecondition T ≥ k∗ for some k∗.

I When p0 > p1, the condition Λ ≤ k is equivalent to T ≤ k∗ for somek∗.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 9 / 13

Page 25: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Example (cont’d)

I Now if p0 < p1, then 1− p0 > 1− p1, and so

0 <p0(1− p1)

p1(1− p0)< 1.

I If p0 > p1, the 1− p0 < 1− p1, and so

p0(1− p1)

p1(1− p0)> 1.

I Hence when p0 < p1, the condition Λ ≤ k is equivalent to thecondition T ≥ k∗ for some k∗.

I When p0 > p1, the condition Λ ≤ k is equivalent to T ≤ k∗ for somek∗.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 9 / 13

Page 26: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Example (cont’d)

I Now if p0 < p1, then 1− p0 > 1− p1, and so

0 <p0(1− p1)

p1(1− p0)< 1.

I If p0 > p1, the 1− p0 < 1− p1, and so

p0(1− p1)

p1(1− p0)> 1.

I Hence when p0 < p1, the condition Λ ≤ k is equivalent to thecondition T ≥ k∗ for some k∗.

I When p0 > p1, the condition Λ ≤ k is equivalent to T ≤ k∗ for somek∗.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 9 / 13

Page 27: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Example (cont’d)

I That is, if p0 < p1, the best test is to reject H0 when T ≥ k∗, wherek∗ is chosen so that P(T ≥ k∗ | p = p0) is the desired level ofsignificance.

I If p0 > p1, the best test is to reject H0 when T ≤ k∗, where k∗ ischosen so that P(T ≤ k∗ | p = p0) is the desired level of significance.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 10 / 13

Page 28: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Example (cont’d)

I That is, if p0 < p1, the best test is to reject H0 when T ≥ k∗, wherek∗ is chosen so that P(T ≥ k∗ | p = p0) is the desired level ofsignificance.

I If p0 > p1, the best test is to reject H0 when T ≤ k∗, where k∗ ischosen so that P(T ≤ k∗ | p = p0) is the desired level of significance.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 10 / 13

Page 29: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Example (cont’d)

I That is, if p0 < p1, the best test is to reject H0 when T ≥ k∗, wherek∗ is chosen so that P(T ≥ k∗ | p = p0) is the desired level ofsignificance.

I If p0 > p1, the best test is to reject H0 when T ≤ k∗, where k∗ ischosen so that P(T ≤ k∗ | p = p0) is the desired level of significance.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 10 / 13

Page 30: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Example

I As in the previous example, suppose X1, X2, . . . , Xn is a randomsample from a Bernoulli distribution with probability of success p andlet T = X1 + X2 + · · ·+ Xn.

I To test

H0 : p = p0

HA : p > p0,

we find k such that P(T ≥ k | p = p0) = α and then reject H0 if theobserved value of T is greater than or equal to k.

I If π is the power function for this test and π∗ is the power functionfor any other test with significance level less than or equal to α, then

π(p) ≥ π∗(p)

for all p ≥ p0.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 11 / 13

Page 31: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Example

I As in the previous example, suppose X1, X2, . . . , Xn is a randomsample from a Bernoulli distribution with probability of success p andlet T = X1 + X2 + · · ·+ Xn.

I To test

H0 : p = p0

HA : p > p0,

we find k such that P(T ≥ k | p = p0) = α and then reject H0 if theobserved value of T is greater than or equal to k.

I If π is the power function for this test and π∗ is the power functionfor any other test with significance level less than or equal to α, then

π(p) ≥ π∗(p)

for all p ≥ p0.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 11 / 13

Page 32: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Example

I As in the previous example, suppose X1, X2, . . . , Xn is a randomsample from a Bernoulli distribution with probability of success p andlet T = X1 + X2 + · · ·+ Xn.

I To test

H0 : p = p0

HA : p > p0,

we find k such that P(T ≥ k | p = p0) = α and then reject H0 if theobserved value of T is greater than or equal to k.

I If π is the power function for this test and π∗ is the power functionfor any other test with significance level less than or equal to α, then

π(p) ≥ π∗(p)

for all p ≥ p0.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 11 / 13

Page 33: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Example

I As in the previous example, suppose X1, X2, . . . , Xn is a randomsample from a Bernoulli distribution with probability of success p andlet T = X1 + X2 + · · ·+ Xn.

I To test

H0 : p = p0

HA : p > p0,

we find k such that P(T ≥ k | p = p0) = α and then reject H0 if theobserved value of T is greater than or equal to k.

I If π is the power function for this test and π∗ is the power functionfor any other test with significance level less than or equal to α, then

π(p) ≥ π∗(p)

for all p ≥ p0.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 11 / 13

Page 34: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Example (cont’d)

I Hence this test is the best test at significance level α no matter whatthe true value of p is.

I We say that this test is the uniformly most powerful (UMP) test ofsize α for the hypotheses

H0 : p = p0

HA : p > p0.

I Similarly, the uniformly most powerful test of size α for the hypotheses

H0 : p = p0

HA : p < p0

is to reject H0 if the observed value of T is less than or equal to somek chosen so that P(T ≤ k | p = p0) = α.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 12 / 13

Page 35: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Example (cont’d)

I Hence this test is the best test at significance level α no matter whatthe true value of p is.

I We say that this test is the uniformly most powerful (UMP) test ofsize α for the hypotheses

H0 : p = p0

HA : p > p0.

I Similarly, the uniformly most powerful test of size α for the hypotheses

H0 : p = p0

HA : p < p0

is to reject H0 if the observed value of T is less than or equal to somek chosen so that P(T ≤ k | p = p0) = α.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 12 / 13

Page 36: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Example (cont’d)

I Hence this test is the best test at significance level α no matter whatthe true value of p is.

I We say that this test is the uniformly most powerful (UMP) test ofsize α for the hypotheses

H0 : p = p0

HA : p > p0.

I Similarly, the uniformly most powerful test of size α for the hypotheses

H0 : p = p0

HA : p < p0

is to reject H0 if the observed value of T is less than or equal to somek chosen so that P(T ≤ k | p = p0) = α.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 12 / 13

Page 37: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Example (cont’d)

I Hence this test is the best test at significance level α no matter whatthe true value of p is.

I We say that this test is the uniformly most powerful (UMP) test ofsize α for the hypotheses

H0 : p = p0

HA : p > p0.

I Similarly, the uniformly most powerful test of size α for the hypotheses

H0 : p = p0

HA : p < p0

is to reject H0 if the observed value of T is less than or equal to somek chosen so that P(T ≤ k | p = p0) = α.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 12 / 13

Page 38: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Example (cont’d)

I However, there is no uniformly most powerful test for testing

H0 : p = p0

HA : p 6= p0.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 13 / 13

Page 39: The Neyman-Pearson Lemmamath.furman.edu/~dcs/courses/math47/lectures/lecture-28.pdfThe Neyman-Pearson Lemma Mathematics 47: Lecture 28 Dan Sloughter Furman University April 26, 2006

Example (cont’d)

I However, there is no uniformly most powerful test for testing

H0 : p = p0

HA : p 6= p0.

Dan Sloughter (Furman University) The Neyman-Pearson Lemma April 26, 2006 13 / 13