hypothesis testing skills set

Upload: kahloon-tham

Post on 07-Jul-2018

217 views

Category:

Documents


0 download

TRANSCRIPT

  • 8/18/2019 Hypothesis Testing Skills Set

    1/6

     Skills Set

    Chapter 7: Hypothesis Testing

    No. Skills Examples of questions involving the skills

    1 To identify

    the null and

    alternativehypothesis

    (If you

    determine it’s

    a one tail test:

    look at sample

    mean)

    Lecture example 1 In the following situations, state suitable null and alternative hypotheses.

    (a)  The mean factory assembly time for a particular electronic component is

    84 seconds. The factory manager wants to test whether the introduction

    of a new assembly process results in a different assembly time.

    (b) In a report, it was stated that the average age of all hospital patients was

    53 years. The hospital director wants to test whether this figure is an

    underestimate.

    Solution

    (a)  Let    be the mean factory assembly time (in seconds) after the

    introduction of the new assembly process.

    H0: 84    against H1: 84    

    (b)  Let    be the average age (in years) of the hospital patients. 

    H0 : 53   against H1 : 53    Tutorial Q4

    A bank has branches in two cities A and B in the same country. The manager ofthe bank claims that the waiting time for a customer to open a new account

    with the bank is not more than 5 minutes.

    0H : 5     against 1H : 5    

    8235 486666667

    150

    ww

    n

    .  

     Note: 5w  corresponds with 1H : 5    

    2 Using G.C (p-value) to

    conduct

    hypothesis

    tests when no

    unknowns are

    present

    Lecture example 2 

    A machine packs sand into bags. The mass of a filled bag follows anormal distribution with mean 1500 g and variance 0.16 g2. A sample of

    10 filled bags is randomly chosen and found to have a mean mass of

    1499.8 g.

    (a) Test whether the sample provides significant evidence, at the 1%level of significance, that the machine packs bags that are

    underweight.

    Solution

  • 8/18/2019 Hypothesis Testing Skills Set

    2/6

    (a) Let X be the mass (in grams) of a filled bag.

    Let     be the mean mass (in grams) of the bags produced by the

    machine.

    0

    1

    H : 1500

    H : 1500

     

     

     

    n = 10,  x  = 1499.8, 0.16 0.4   .

    Under H0,0.16

    ~ N 1500,10

     X  

    .

    Test statistic, Z 1500

    ~ N(0, 1)0.4

    10

     X    under H0.

    Using z -test, 1.58113883 z   . p-value P( 1.58113883) Z  = 0.0569.

    Conclusion: Since p-value = 0.0569 > 0.01 , we do not reject H0 at

    the 1% level of significance. There is insufficient evidence to saythat the machine packs bags that are underweight.

    3 Using Test-Statistic and

    Critical Region

    when there are

    unknowns in

    the question.

    Tutorial Q10b 

    A random sample of 50 packets of ‘Nilo Bar’ snacks is weighed and the mass,

     x  grams, is recorded. The results are summarised by

    ( x   – 150) = –250, ( x   – 150)2 = 3000.

    The population mean mass is     grams. A test is carried out at the 1%

    significance level with the following hypotheses:

    0 : H    0    

    :1 H    0    

    Given that 0 H   is rejected in favour of H1, find the set of possible values of

    0  .

    Solution

     x = 150

    150 x

    n

      250 150 145

    50

     

    2 s  =

      2

    2 1501150

    1

     x x

    n n

     

      2

    25013000

    49 50

      35.714  

  • 8/18/2019 Hypothesis Testing Skills Set

    3/6

    0Test statistic: ~ 0, 135.714

    50

     X  Z N 

     

     

    Since0 H 

     is rejected in favour of H1,

    Critical region: 2.576 or 2.576 z z   

    0

    0

    1452.576

    35.714

    50

    147.18

     

     

     

    0

    0

    1452.576

    35.714

    50

    142.82

     

     

     

    0 0 0: 142.82 or 147.18    

    4 Identify theneed to use

    Central Limit

    Theorem for

    distribution of

    sample mean.

    (n large and

    population not

    known to be

    normal)

    Lecture example 5Clara, who has diabetes, has to monitor her blood glucose levels which vary

    throughout a week. The results from a sample of 75 readings,  x , taken at

    random times over a week, are summarized by

    511.5 x  and 2 4027.89 x   .(ii) State, giving a reason, whether we can conclude that the alternative

    hypothesis0

      is to be accepted if the blood glucose level cannot be

    assumed to have a normal distribution.

    Solution

    (ii) Since the sample size, n, is sufficiently large, by the Central Limit

    Theorem, the mean blood glucose level is approximately normally

    distributed, so the alternative hypothesis0    can still be accepted.

    6 conduct t-testsfor a

    population

    mean based on

    a sample taken

    from a normal

    population with

    unknown

    variance and a

    small sample

    size.

    Assumption

    Lecture example 7An automatic coffee dispensing machine is set to dispense 440 cm

    3 of coffee

    into a mug. A random sample of 12 filled mugs was taken and the mugs were

    found to contain the following amounts of coffee, in cm3.

    420 446 372 430 436 441

    433 422 445 422 438 442

    Assuming no spillage and that the amount of coffee dispensed follows a normal

    distribution, test at the 5% level of significance, whether the machine is

    dispensing too little coffee.

    Solution

  • 8/18/2019 Hypothesis Testing Skills Set

    4/6

    phrasing.

    Using data lists

    vs stats values.

    Let    be the mean amount of coffee in a mug (in cm3).

    H0 :   = 440

    H1 :   < 440

    n = 12,  x = 428.92, s = 20.07.

    Under H0, test statistic, T  = 440 X S 

    n

    t (11).

    Using t -test, t  = –1.912418829.

     p-value P( –1.912418829)T  0.0411.

    Conclusion: Since p-value = 0.0411 < 0.05, we reject H0 at the 5% level of

    significance. There is sufficient evidence to conclude that the machine is

    dispensing too little coffee.

    7 Comparing thedifferences

    between 1 tail

    and 2 tail test,

    z test and t-

    tests

    Tutorial Question 7In a test at the 5% significant level it is found that there is significant evidence

    that the population mean talk-time is less than 5 hours. Using only this

    information, and giving a reason in each case, state whether each of the

    following statements is

    (i) 

    necessarily true, (ii) necessarily false,

    (ii) 

    or (iii) neither necessarily true nor necessarily false.

    (a) There is significant evidence at the 10% significance level that the

    population mean talk-time is less than 5 hours.

    (b) There is significant evidence at the 5% significance level that the

    population mean talk-time is not 5 hours.

    Solution

    (a) Test at 10% level of significance: the p-value remains the same; hence if p-

    value 0.05 , it is definitely 0.1 , and we reject 0H . This statement is

    necessarily true.

    (b) Test0H : 5    vs 1H : 5    at 5% level of significance: new  p -value is

    twice old  p -value; new p-value may or may not be 0.05 . This statement is

    neither necessarily true nor necessarily false.

  • 8/18/2019 Hypothesis Testing Skills Set

    5/6

     

    8 Comparing thedifferences

    between z- test

    and t-tests

    Tutorial Question 8(b)After the implementation of another teaching pedagogy, the SAT score of 10

    students are collected. To investigate the effectiveness of this pedagogy, a

    hypothesis test is carried out at the %α  level of significance.

    (ii) If the null hypothesis is not rejected when a t -test is carried out, explain

    whether it is necessarily true that the same conclusion is obtained when

    a z-test is carried out at the same significance level.

    Let andt z  p p   be the  p-values obtained using a t -test and z-test

    respectively. Note that for the same test statistic,  >t z  p p .

    Since H0 is not rejected for a t -test,  pt   >100

     . There are two possible

    conclusions for a z-test.

    OR

     Z

    N(0,1)

    t(  )

    Test statistic

    t  p

     

     z  p 

    N(0,1)

    t(  )

     z  

       Zt  

     

  • 8/18/2019 Hypothesis Testing Skills Set

    6/6

     

    Reason:

    For a fixed level of significance,   ,  z  

    < t  

    (refer to graph above).

    When H0 is not rejected for a t -test, there are two possible conclusions

    for a z-test:

    1)  z  

    < test statistic < t  

    : H0 will be rejected if z-test is used.

    2) test statistic <  z  

    < t  

    : H0 will not be rejected if z-test is used.

    9 CommonAssumptions

    1.  For t-test, we may need to assume population is normallydistributed if sample size is given to be small and population

    variance is unknown.

    2.  For z-test, we do not need to assume population is normally

    distributed if sample size is large.3.  Sample are independently chosen.