Download LECTURE 16 Tutorial 7: #9.11.2, 9.11.6, 9.11.10, 9.11.17. Example

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts
no text concepts found
Transcript
LECTURE 16
Tutorial 7: #9.11.2, 9.11.6, 9.11.10, 9.11.17.
Example A Let X1, . . . , Xn be a random sample from N (µ, σ 2) where σ 2 is known.
Consider the two simple hypotheses:
H0 : µ = µ0 versus HA : µ = µ1
where µ0 < µ1 are given (known) constants.
Let the significance level be α. Writing
X = (X1, . . . , Xn), the loglikelihood ratio
is
f0(X)
log
f1(X)
Pn
1
exp[− 2 i=1(Xi − µ0)2]
2σ
= log
Pn
1
exp[− 2σ2 i=1(Xi − µ1)2]
n
X
1
= − 2
(Xi − µ0)2]
2σ
i=1
1
n
1 X
+ 2
(Xi − µ1)2
2σ
i=1
1
2 − nµ2 ].
=
[2n
X̄(µ
−
µ
)
+
nµ
0
1
1
0
2σ 2
Since log is a strictly increasing function,
the likelihood ratio test is of the form: reject
H0 if
X̄ > x0
where x0 is a constant chosen so as to give
the test the desired significance level α.
More precisely, under H0,
X̄ ∼ N (µ0, σ 2/n).
Hence
X̄ − µ0 x0 − µ0
√ )
P (X̄ > x0) = P ( √ >
σ/ n
σ/ n
= α.
2
This implies that x0 satisfies
x0 − µ0
√ = zα
σ/ n
where P (Z > zα) = α and Z ∼ N (0, 1).
Consequently we conclude that the decision rule based on the likelihood ratio is
√
• Reject H0 if X̄ > µ0 + zασ/ n (the
conclusion is said to be significant),
√
• Do not reject H0 if X̄ ≤ µ0 + zασ/ n
(the conclusion is said to be not significant).
Remark The text uses “accept H0” instead of “do not reject H0” which is not
strictly correct.
Accept H0 gives the connotation that H0
is true and HA is false, whereas in fact if the
test is insignificant, we are essentially back
to square one: we still do not know which of
the two hypotheses, H0 or HA, is true.
3
A key point of note is that we can only
prove HA to be true and not H0. This is
a consequence of the fact that testing hypotheses is analogous to “proof by contradiction” in mathematics.
This leads to an asymmetry between in the
treatment of H0 and HA.
Thus when formulating a hypotheses testing problem, the hypothesis that you want
to show to be true must be the alternative
hypothesis HA.
Another remark Example A is typical
of the way that the Neyman-Pearson lemma
is used.
First write down the likelihood ratio and
observe that small values of it correspond in
a 1-1 manner with extreme values of a test
statistic (in this case X̄).
4
Knowing the null distribution of the test
statistic makes it possible to choose a critical value (in this case x0) that produces the
desired significance level α.
The main weakness of the Neyman-Pearson
lemma is that it considers only a simple null
hypothesis H0 versus a simple alternative
hypothesis HA.
In practice the hypotheses of interest may
not be simple hypotheses but are usually
composite hypotheses.
A hypothesis is called a composite hypothesis if it does not completely specify the probability distribition. E.g.,
HA : µ ≤ µ1.
5
Chapter 9.2.1: Specification of the
significance level and the concept of
a p-value
In practice, the specification of the significance level α of a test is rather arbitrary
even though it is clear that α should be small
(since α is the probability of type I error).
Commonly used values of α are 0.01, 0.05,
0.1. α = 0.05 seems to be the scientific
standard.
A criticism against hypotheses testing is
that one must either reject or not reject H0
where no such decision is really required.
The p-value is a way of applying hypotheses testing without the need for making such
dichotomous decisions.
6
The p-value is defined as the probability
under H0 of a result to be as or more extreme than that actually observed. In Example A, if the observed sample mean is x̄,
then the p-value of the test is
p = P (X̄ ≥ x̄)
where X̄ ∼ N (µ0, σ 2/n).
Thus we reject H0 if the p-value < α, and
do not reject H0 if p-value ≥ α.
Chapter 9.2.3: Uniformly most powerful tests
The optimality result of the Neyman-Pearson
lemma requires that both hypotheses be simple.
In some cases, this theory can be extended
to include composite hypotheses.
7
If the alternative hypothesis H1 is composite, a test that is most powerful for every
simple alternative in H1 is said to be uniformly most powerful.
Example A contd Suppose we are interested in testing
H0 : µ = µ0 versus H1 : µ > µ0.
Here H0 is a simple hypothesis while H1
is a composite hypothesis. Recall that in
testing
H0 : µ = µ0 versus H1 : µ = µ1
for any µ1 > µ0, the most powerful test is
the likelihood ratio test given by X̄ > x0,
where x0 depends on µ0 but not on µ1.
This implies that this test is most powerful
for every alternative in H1 and we conclude
that the likelihood ratio test is uniformly
most powerful.
8
Remark In typical composite hypotheses
situations, a uniformly most powerful test
does not exist unfortunately.
9