Title: Hypothesis Testing using Pvalues
1Hypothesis Testing using P-values
- Perform Step 1 and Step 2 as before when using
rejection points - Compute the test statistic, z or t.
- Compute the probability of obtaining such an
extreme test statistic by pure chance, if the
Null hypothesis were true. This is called the
p-value of the test. - Reject or fail to reject the Null Hypothesis by
determining the p-value is less than or greater
than a. - Real-world interpretation
2(No Transcript)
3Interpreting p-values
- All statistical packages give p-values in the
standard output. - When we reject Ho we say the test is significant.
- If p-value lt .01, highly significant
(overwhelming evidence in support of research
hypothesis) - If p-value between .01 and .05, significant
(strong evidence) - If p-value between .05 and .10, slightly
significant (weak evidence) - If p-value gt .10, not significant (no evidence)
4(No Transcript)
5Comparing p-value with alpha Right Tail
If the alternative hypothesis is ?gt20, this is a
right-tailed test with all the a .05 at the
right tail. The p-value (to compare with a) is
the area cut off at the right tail by the
calculated z.
? .05
p-value
z
6Comparing p-value with alpha Left Tail
- If the alternative hypothesis is ? lt 20 and a
.10, - this is a left-tailed test with all the .10 at
the left tail. The p-value (to compare with a) is
the area cut off at the left tail by the
calculated z.
?.1
p-value
z (usually negative)
7Example The p-Value for Greater Than
Testing H0 ? ? 50 vs Ha ? gt 50 using rejection
points and p-value. Trash Bag The p-value or the
observed level of significance is the probability
of observing a value of the test statistic
greater than or equal to z when H0 is true. It
measures the weight of the evidence against the
null hypothesis and is also the smallest value of
? for which we can reject H0.
8Hypothesis Test Example ex. 8.7/8.30
- What are we given? n 65 s 2.6424 xbar
42.954 - For this exercise well consider s to represent
the true s - Step 1, establish hypotheses
- H0 ? 42 vs. Ha ? gt 42
- Step 2, specify significance level. a .01
(given) - Step 3, compute the test statistic
- z (42.954-42)/(2.6424/sqrt65) 2.91
- Step 4, determine the p-value. Z-table gives P(z
lt 2.91) 0.9982. So, P(z gt 2.91) 1- 0.9982
.0018
9Hypothesis Test Example ex. 8.7/8.30
- Step 5, decision reject Ho since p-value (.0018)
lt ? .01 - Step 6, conclusion within context Conclude there
is very strong evidence that a typical customer
is very satisfied since we reject the notion that
the average rating is 42 with such a small
p-value
10Hypothesis Test Example ex. 8.9/8.32
- What are we given? n 100 s 32.83 xbar
86.6 - For this exercise well consider s to represent
the true s - Step 1, establish hypotheses
- H0 ? 90 vs. Ha ? lt 90
- Step 2, specify significance level. a .05
(arbitrary) - Step 3, compute the test statistic
- z (86.6 - 90)/(32.83/sqrt100) -1.035
- Step 4, determine the p-value. Z-table gives P(z
lt -1.04) 0.1492.
11Hypothesis Test Example ex. 8.9/8.32
- Step 5, decision fail to reject Ho since p-value
(.1492) gt ? .05 - Step 6, conclusion within context Conclude there
is no evidence that the mean audit delay is less
than 90 days since we fail to reject the notion
that the mean is 90
12Two Tailed vs. One Tailed Tests
If the alternative is ? ? 20, the test is
two-tailed. a is shared between both tails of the
z-curve. The p-value twice the area cut off at
the tail by the computed z. This p-value is then
compared with a.
a/2 .025
?/2.025
½ p-value
z
13Hypothesis Test Example ex. 8.11/8.45a
- What are we given? n 36 s 0. 1 xbar
16.05 - For this exercise well consider s to represent
the true s - Step 1, establish hypotheses
- H0 ? 16 vs. Ha ? ? 16
- Step 2, specify significance level. a .01
(given) - Step 3, compute the test statistic
- z (16.05 - 16)/(0.1/sqrt36) 3.0
- Step 4, determine the p-value. Z-table gives P(z
lt 3) 0.9987, P(z gt 3) 1 - .9987 0.0013. So
2-tailed p-value 20.0013 0.0026
14Hypothesis Test Example ex. 8.11/8.45
- Step 5, decision reject Ho p-value (.0026) lt ?
.01 - Step 6, conclusion within context Conclude there
is very strong evidence that the filler needs
readjusting since we reject the notion that the
mean is 16
15Estimating P-value with t-tables Sigma Unknown.
Credit Card Case (pg 322)
- What are we given? n 15 s 1.538 xbar
16.827 ? .05 - Step 1, establish hypotheses
- H0 ? ? 18.8 vs Ha ? lt 18.8
- Step 2, set significance level. a .05 (given)
- Step 3, compute the test statistic
- Step 4b, estimate p-value df14, P(t lt 4.14)
.0005. So P(t lt 4.97) lt .0005
16Estimating P-value with t-tables Sigma Unknown.
Credit Card Case (pg 322)
Step 5, decision reject Ho since p-value
(lt.0005) lt a .05 Step 6, conclusion within
context there is overwhelming evidence that the
current mean credit card interest rate is less
than 18.8.
17MegaStat Output for Example 1
18Estimating p-value, Example 2
- What are we given? n 30 s 15 x 21 ?
.10 - Step 1, establish hypotheses
- H0 ? 20 vs. Ha ? gt 20
- Step 2, set significance level. a .10 (given)
- Step 3, compute the test statistic
- t (21 - 20)/2.74 0.365
- Step 4b, estimate the p-value. Using df 29,
t-table gives P(T gt 1.311) .10. So, P(T gt t
.365) gt .10 Best estimate of p-value is gt 0.10
19SExbar 15/?30 2.74
Using df 29, t-table gives P(T gt 1.311)
.10 P-value P(T gt t) gt .10
0.10
t 0.365
1.311
20Hypothesis Test Example 2
- Step 5, decision fail to reject Ho since p-value
(gt.10) gt ? .10 - Step 6, conclusion within context no context
given but we can say there is insufficient
evidence that the population mean is greater than
20. Notice we do NOT say we have evidence that m
is less than or equal 20. In other words we can
prove Ha but not Ho
21MegaStat Output for Example 2
22Estimating P-value, Example 3
- What are we given? n 400 s 15 x 23 ?
.05 - Step 1, establish hypotheses
- H0 ? 20 vs. Ha ? ? 20
- Step 2, set significance level. a .05 (given)
- Step 3, compute the test statistic
- t (23 20)/0.75 4.0
- Step 4b, estimate the p-value. Using df 8,
t-table gives P(T gt 3.291) .0005. So, P(T gt t
4) lt .0005. Since test is two tailed, p-value
lt 20.0005 i.e. lt 0.001
23Since we have a 2-tailed test, p-value 2 x P(T
gt t). 2 x .0005 .001, so p-value lt .001 lt a
(.05). Reject H0 since p-value lt a
.0005
½ p-value lt .0005
3.291
4.0
24Hypothesis Test Example 3
- Step 5, decision reject Ho since p-value (lt.001)
lt ? .05 - Step 6, conclusion within context no context
given but we can say there is very strong
evidence that the population mean is not equal to
20 and is most likely gt 20 since we rejected Ho
at the upper tail.
25MegaStat Output for Example 3
26Estimating P-value, Example 4
- What are we given? n 25 s 4 x 18.7 ?
.05 - Step 1, establish hypotheses
- H0 ? 20 vs. Ha ? lt 20
- Step 2, set significance level. a .05 (given)
- Step 3, compute the test statistic
- t (18.7 20)/0.80 1.63
- Step 4b, estimate the p-value. Using df 24,
t-table gives P(T lt 1.711) .05 and P(T lt
1.318) .10 Since 1.711 lt (t 1.63) lt
1.318 , p-value is between 0.05 and 0.10
27Using df 24, t-table gives P(T lt 1.711) 0.05
and P(T lt 1.318) 0.10 . Since t 1.63 which
lies between 1.711 and 1.318 then 0.05 lt
P-value lt 0.10
.10
.05
-1.711 -1.63
-1.318
28Hypothesis Test Example 4
- Step 5, decision F.T.R. Ho since p-value
(between .05 and .10) gt ? .05 - Step 6, conclusion within context no context
given but we can say there is only weak evidence
that the population mean is less than 20 and the
finding is insignificant at the 5 level
29MegaStat Output for Example 4