@let@token ch6.2 part i hypothesis testingjagels/mat217/week1/ch6_2a.pdf · 2020. 3. 31. · quiz...

28
CH6.2 Part I Hypothesis testing

Upload: others

Post on 03-Feb-2021

2 views

Category:

Documents


0 download

TRANSCRIPT

  • CH6.2 Part I

    Hypothesis testing

  • Hypothesis testing is a formal method for testing hypothesis aboutpopulation parameters.

    Example:

    The average height of 12 year olds in IN is 5’5” or 65inches. The school superintendant in Jefferson Countybelieves that the average height of 12 year olds is greaterin her schools.

    There are two quantities involved in this statement. The first is theestablished mean, µ = 65 inches. This is the null hypothesis, H0.

    The second is the superintendant’s hypothesis that µ > 65 inches.This is the alternative hypothesis, Ha.

  • These are combined into the declaration

    H0 : µ = 65

    Ha : µ > 65

    Quiz: Write the formal declaration for the following statement.

    The average income of IN adults is $40,000. The taxassesor in Jefferson County believes that it is higher in hiscounty.

  • These are combined into the declaration

    H0 : µ = 65

    Ha : µ > 65

    Quiz: Write the formal declaration for the following statement.

    The average income of IN adults is $40,000. The taxassesor in Jefferson County believes that it is higher in hiscounty.

    Soln

    H0 : µ = $40000

    Ha : µ > $40000

  • Components of a hypothesis test for µ (normal populations orlarge samples).

    Null Hypothesis : H0 : µ = µ0

    Alternative Hypothesis : Ha : µ > µ0 right tail testHa : µ < µ0 left tail testHa : µ 6= µ0 two tail test

    µ0 is some value, for example, it is $40,000 in the quiz.

    Ha can assume 3 forms. See the graphs on p410 for an explanationof the “tails”.

  • ExampleThe mean weight of steers in a large feed lot is 2500 lbs.An inspector believes it differs.

    “differ” means “not equal to”. The formal declaration is a two tailtest

    H0 : µ = 2500

    Ha : µ 6= 2500

    Quiz: Write the formal declaration for the following statement andstate whether it is right, left, or two tail.

    The average number of pulses a heart beats is 85/min. Itis believed that this average is less for joggers.

  • ExampleThe mean weight of steers in a large feed lot is 2500 lbs.An inspector believes it differs.

    “differ” means “not equal to”. The formal declaration is a two tailtest

    H0 : µ = 2500

    Ha : µ 6= 2500

    Quiz: Write the formal declaration for the following statement andstate whether it is right, left, or two tail.

    The average number of pulses a heart beats is 85/min. Itis believed that this average is less for joggers.

    Soln: Left tailH0 : µ = 85

    Ha : µ < 85

  • The test statistic

    We return to our first example. The school superintendant has setup the formal test

    H0 : µ = 65

    Ha : µ > 65

    She takes a sample of n = 25 Jefferson County 12 year olds andmeasures each. The result is the statistic x = 68 inches. Thestandard deviation of the population is σ = 5.

    She now finds the test statistic z . Recall

    z =stat - parameter

    σstat

    In our case this is

    z =x̄ − µσ/

    √n

  • The key to hypothesis testing is that it is assumed that H0 istrue. In our example, this is that µ = 65. We now compute zusing the information on the previous slide.

    z =68 − 655/√25

    = 3/1

    = 3

    In other words, if H0 is true, the statistic, x = 68, is 3 standarddeviations from the mean.She now finds the P value. This is a right tail test so (see p410)

    P = P(Z > 3)

    = P(Z < −3)= .0013

    where Table A is used.

  • The decision

    The P value is the probability that x = 68 will occur if H0 is true.This probability is quite small in our case. Logically, one of twothings occurred.

    1. An improbable event occurred.

    2. Our assumption about H0 is false.

    In the world of hypothesis testing, we assume the 2nd item holds.

    Decision: Reject H0 in favor of the alternative, Ha, that theaverage heights of 12 year olds in Jefferson County is greater thanthat in the state as a whole.

  • QuizWe return to our first quiz. The tax assesor sets up the formal test

    H0 : µ = $40000

    Ha : µ > $40000

    He takes a sample of n = 100 Jefferson County adults anddetermines their yearly salary. The result is the statisticx = $42000. The standard deviation of the population isσ = $10000.

    1. Find the test statistic, z

  • QuizWe return to our first quiz. The tax assesor sets up the formal test

    H0 : µ = $40000

    Ha : µ > $40000

    He takes a sample of n = 100 Jefferson County adults anddetermines their yearly salary. The result is the statisticx = $42000. The standard deviation of the population isσ = $10000.

    1. Find the test statistic, z

    z =42000 − 4000010000/

    √100

    = 2000/1000

    = 2

    (Next frame).

  • Quiz continued

    2. Find the P value.

  • Quiz continued

    2. Find the P value.

    P = P(Z > 2)

    = P(Z < −2)= .0228

    3. Decision?

  • Quiz continued

    2. Find the P value.

    P = P(Z > 2)

    = P(Z < −2)= .0228

    3. Decision?

    The probability of .0228 gives a fairly small chance that xwill equal $42,000 if H0 is true. Reject H0 in favor of thealternative.

  • QuizSame as before except x = $41, 000.

    1. Find the test statistic, z

  • QuizSame as before except x = $41, 000.

    1. Find the test statistic, z

    z =41000 − 4000010000/

    √100

    = 2000/1000

    = 1

    2. Find the P value.

  • QuizSame as before except x = $41, 000.

    1. Find the test statistic, z

    z =41000 − 4000010000/

    √100

    = 2000/1000

    = 1

    2. Find the P value.

    P = P(Z > 1)

    = P(Z < −1)= .1587

    3. Decision?

  • QuizSame as before except x = $41, 000.

    1. Find the test statistic, z

    z =41000 − 4000010000/

    √100

    = 2000/1000

    = 1

    2. Find the P value.

    P = P(Z > 1)

    = P(Z < −1)= .1587

    3. Decision? See next slide.

  • Interpretation

    Decision: x will have the value $41,000 almost 16% (.1587) ofthe time if H0 is true. This is not rare. Do Not Reject H0.

    Logic of the test: We do not say in the above case that we“accept H0”. All that is being stated is that we do not havesufficient evidence to reject it based on the test. The test is said tobe significant if H0 is rejected; otherwise the test failed and wesay it is “insignificant”.

    We will discuss significance in the next set of slides

  • Computing PIt is important to understand that the P value depends on thealternative hypothesis Ha. View the graphs of p410,411 whileconsidering the following example.Example: A test of significance is conducted with the result thatz = −1.5.

    case I Ha : µ > −1.5: (right tail test). P is the area to the right ofz = −1.5.

    P = P(Z > −1.5)= P(Z < 1.5)

    = .9332

    case II Ha : µ < −1.5: (left tail test). P is the area to the left ofz = −1.5.

    P = P(Z < −1.5)= .0668

  • Computing P continued

    case III Ha : µ 6= −1.5: (two tail test). P is the sum of the areas tothe right of z = 1.5 and to the left of z = −1.5.(see fig 6.11, p411).

    P = P(Z > 1.5) + P(Z < −1.5)= 2P(Z < −1.5)= 2 ∗ (.0668)= .1336

    where symmetry is used in the 2nd step.

    Observe: A two tail test is twice the probability of a one tail testand thus sets a higher standard.

  • Quiz

    A test of significance is conducted with the result that z = 2.12.Find the P value for each case.

    case I Ha : µ > 2.12: (right tail test).

  • Quiz

    A test of significance is conducted with the result that z = 2.12.Find the P value for each case.

    case I Ha : µ > 2.12: (right tail test). Ans:

    P = P(Z > 2.12)

    = P(Z < −2.12)= .0170

    case II Ha : µ < 2.12: (left tail test).

  • Quiz

    A test of significance is conducted with the result that z = 2.12.Find the P value for each case.

    case I Ha : µ > 2.12: (right tail test). Ans:

    P = P(Z > 2.12)

    = P(Z < −2.12)= .0170

    case II Ha : µ < 2.12: (left tail test). Ans:

    P = P(Z < 2.12)

    = .9830

  • Quiz continued

    case III Ha : µ 6= 2.12: (two tail test).

  • Quiz continued

    case III Ha : µ 6= 2.12: (two tail test). Ans:

    P = P(Z > 2.12) + P(Z < −2.12)= 2P(Z < −2.12)= 2 ∗ (.0170)= .0340

  • Homework

    p417: 35, 37, 39, 42, 54, 55, 56.

    Do hwwed.pdf for this week.