SlideShare a Scribd company logo
1 of 58
Download to read offline
Lecture 7
Hypothesis Testing: An
    Introduction
Topics
Steps in a hypothesis test.
Large sample tests for µ: two-tail.
Large sample tests for µ: one-tail.
Type I and Type II errors.
Section 7.4

Steps in a Hypothesis Test
Definitions
In statistics, a hypothesis is an idea, an
assumption, or a theory about the characteristics
of one or more variables in one or more
populations.
A hypothesis test is a statistical procedure that
involves formulating a hypothesis and using
sample data to decide on the validity of the
hypothesis.
Definitions (cont.)
The null hypothesis is a statement about a
parameter of the population. It is labeled H0.
The alternative hypothesis is a statement about a
parameter of the population that is opposite to
the null hypothesis. It is labeled HA.
A test statistic is a number that captures the
information in the sample data. It is used to
decide between the null and alternative
hypotheses.
Definitions (cont.)
The significance level, α, is the maximum
probability tolerated for rejecting a true null
hypothesis.
The p value is the probability of a more extreme
departure from the null hypothesis than the
observed data.
Definitions (cont.)
The rejection region is the range of values of
the test statistic that will lead us to reject the
null hypothesis. It is defined by the critical
value. The area of the rejection region is α, the
significance level.
Goals
To understand the difference between
estimation and testing.
To learn the 5 steps involved in a hypothesis
test.
Estimation Versus Testing
Estimation is the process of providing a
numerical value (point) or values (interval) for
a population parameter based on information
in a sample.
Testing is a procedure for assessing whether
sample data are consistent with statements
(hypotheses) made about the population.
Steps
Step 1: Set up the null and alternative
hypotheses.
Step 2: Define the test procedure (includes
selecting a test statistic, an α level and a
rejection region).
Step 3: Collect the data and calculate the test
statistic and the p value.
Step 4: Decide whether to reject the null
hypothesis.
Steps (cont.)
Step 5: Interpret the results in the context of
the problem.
Section 7.6

Large-Sample Test of the Mean:
        Two-Tail Tests
Definitions
A large-sample test of the mean is conducted
when the characteristic of interest is the
population mean, µ, and either of these
situations exists:
  the population standard deviation, σ, is known
  (regardless of sample size)
  the population standard deviation, σ, is unknown
  but n ≥ 30
Definitions (cont.)
A two-tail test of the population mean has
these null and alternative hypotheses:
  H0: µ = [specified number]
  HA: µ ≠ [specified number]
Goal
To apply the 5 steps of a hypothesis test to a
two-tail test of a population mean, µ, based on
information in a large sample (n ≥ 30).
Example – Humerus Bones
Humerus bones from the same species of
animal tend to have approximately the same
length-to-width ratios.
For a particular species (Species A) the mean
ratio is 8.5.
Suppose 41 fossils of humerus bones of an
unknown species were unearthed at an
archeological site.
Example – Humerus Bones
Suppose the length-to-width ratios of the 41
fossils were calculated.
It is believed (hypothesized) that this site was
not populated by Species A.
Example – Humerus Bones
Step 1: Set up the null and alternative
hypotheses.
Let µ = the mean ratio for the site.
H0: was populated by Species A
H0: µ = 8.5
HA: was not populated by Species A
HA: µ ≠ 8.5
Example – Humerus Bones
Step 2: Define the test procedure.

                                     X − µ0
Consider as our test statistic  Z=
                                     s n
where µ0 = 8.5
This measures the distance of between the
mean ratio of the sample and the mean for
Species A.
We should reject H0 for large values of |Z|.
Example – Humerus Bones
Consider as our rejection region |Z| > z.
This means we reject H0 if Z > z or Z < -z.
We need to choose z so that
    α = P(reject a true H0)
       = P(Z > z) + P(Z < -z), assuming µ = 8.5
If H0 is true then Z ~ N(0,1).
Example – Humerus Bones




α/2                        α/2




      -z        0     z
      = -zα/2         = zα/2
Example – Humerus Bones
So we reject H0 if |Z| > zα/2
Equivalently, reject H0 if Z > zα/2 or Z < -zα/2
Let’s choose α = 0.05
zα/2 = z.025 =1.96
Reject H0 if Z > 1.96 or Z < -1.96
Example – Humerus Bones
Step 3: Collect the data and calculate the test
statistic and the p value.
For the n = 41 ratios we have     X
                                  = 9.258 and s
= 1.404

     9.258 − 8.5
Z=                 = 3.46
     1.404   41
Example – Humerus Bones
p value = P(|Z| > |3.46|)
        = P(Z > 3.46) + P(Z < -3.46)
        = 2P(Z < -3.46)
        = 2(.0003)
        = 0.0006
Example – Humerus Bones
Step 4: Decide whether to reject the null
hypothesis.
Z = 3.46
Rejection region: Z > 1.96 or Z < -1.96
Reject H0: µ = 8.5
Accept HA: µ ≠ 8.5
Example – Humerus Bones
Step 5: Interpret the results in the context of
the problem.
The fossils found at the site are not consistent
with those that would come from Species A.
Hence, the site was not populated by species
A.
p Value Versus α
The p value is the smallest value of α for
which we could reject H0.
If p value < α then reject H0.
If p value ≥ α then do not reject H0.
A p value can be used in place of a rejection
region.
Example – Humerus Bones
α = 0.05
p value = 0.0006
p value < α
Reject H0: µ = 8.5
Section 7.7

What Error Could You Be
       Making?
Definitions
A Type I error is made when we reject the null
hypothesis and the null hypothesis is actually
true.
A Type II error is made when we fail to reject
the null hypothesis and the null hypothesis is
actually false.
The probability of making a Type I error is
labeled α.
The probability of making a Type II error is
labeled β.
Goal
To learn from our mistakes.
Truth versus Decision

                                 Truth


Decision            H0 true                HA true


Believe H0       Right choice            Type II error


Believe HA        Type I error           Right choice
Example – Humerus Bones
H0: site was populated by Species A
H0: µ = 8.5
HA: site was not populated by Species A
HA: µ ≠ 8.5
Type I error = conclude the site was not
populated by Species A when it actually was.
Example – Humerus Bones
Type II error = conclude the site was populated
by Species A when it actually was not.
Choosing α
So far our hypothesis tests allow us to choose
α.
In many (but not all) applications a Type I
error is more costly than a Type II error.
As α decreases, β increases.
As β decreases, α increases.
Whichever error is the most costly is the
probability of which you need to minimize.
Example – Humerus Bones
Suppose it would be most embarrassing to
claim that the site was not populated by
Species A when it actually was.
Make α small (α = 0.01).
Suppose it would cost you your academic
career to say that the site was populated by
species A when it actually was not.
Make β small (α = 0.10).
Reject H0 Versus Don’t Reject H0
Clearly, if we reject H0 then we accept HA.
However, if we do not reject H0 does this
imply that we accept H0?
No. At least not in this class.
Type I error = reject a true H0
P(Type I error) = α (known)
Type II error = accept a false H0
P(Type II error) = β (unknown, for now)
Reject H0 Versus Don’t Reject H0
Since we know α we will allow ourselves the
risk of rejecting H0 when H0 is true.
However, since we do not know β we will not
risk accepting H0 when H0 is false.
If we do not reject H0 we will conclude that
there is insufficient evidence in the sample to
say H0 is false.
Section 7.8

Which Theory Should Go into
   the Null Hypothesis?
Definitions
A two-tail test of the population mean has
these null and alternative hypotheses:
  H0: µ = µ0
  HA: µ ≠ µ0
A lower-tail test of the population mean has
these null and alternative hypotheses:
  H0: µ ≥ µ0
  HA: µ < µ0
Definitions (cont.)
An upper-tail test of the population mean has
these null and alternative hypotheses:
  H0: µ ≤ µ0
  HA: µ > µ0
Two-Tail Tests
H0: µ = µ0
H A : µ ≠ µ0
HA: µ > µ0 or µ < µ0
In these cases we wish to show that the mean
is not some specified value (research
hypothesis).
With this end, we assume the complement to
be true (H0) until we have sufficient evidence
to reject H0 (accept HA).
Example – Humerus Bone
µ = mean ratio for the site
HA: µ ≠ 8.5
HA: µ < 8.5 or µ > 8.5
H0: µ = 8.5
Lower-Tail Tests
H0: µ ≥ µ0
H A : µ < µ0
In these cases we usually wish to show that the
mean is less than some specified value
(research hypothesis).
With this end, we assume the complement to
be true (H0) until we have sufficient evidence
to reject H0 (accept HA).
Example – Vending Machine
µ = average amount of beverage dispensed into
a 12 ounce cup
You believe that you are being ripped off by
this vending machine, i.e., µ < 12 ounces.
HA: µ < 12 ounces
H0: µ ≥ 12 ounces
Upper-Tail Tests
H0: µ ≤ µ0
H A : µ > µ0
In these cases we usually wish to show that the
mean is greater than some specified value
(research hypothesis).
With this end, we assume the complement to
be true (H0) until we have sufficient evidence
to reject H0 (accept HA).
Example – Grade Inflation
µ = 2004-05 GPA at UCF
The historical average is 2.7
Suppose you wish to show that UCF is
currently experiencing grade inflation, i.e., µ >
2.7
HA: µ > 2.7
H0: µ ≤ 2.7
Section 7.9

One-Tail Tests of the Mean:
     Large Sample
Lower-Tail Test
H0: µ ≥ µ0 versus HA: µ < µ0

                      X − µ0
Test statistic: Z =
                      s   n

Rejection region: Z < z
α = P(Z < z), given H0 true
α




              0
    z = -zα
Lower-Tail Test
z = -zα
Rejection region: Z < -zα
p value = P(Z < observed Z)
Upper-Tail Test
H0: µ ≤ µ0 versus HA: µ > µ0

                      X − µ0
Test statistic: Z =
                      s   n

Rejection region: Z > z
α = P(Z > z), given H0 true
α




0
    z = zα
Upper-Tail Test
z = zα
Rejection region: Z > zα
p value = P(Z > observed Z)
Example – Grade Inflation
µ = 2004-05 GPA at UCF
The historical average is 2.7
Suppose you wish to show that UCF is
currently experiencing grade inflation.
Suppose that from a sample of 64 students we
had an average GPA of 2.85 with a standard
deviation of 0.55.
Example – Grade Inflation
Let the Type I error be 0.05.
Step 1:
  HA: µ > 2.7
  H0: µ ≤ 2.7
Step 2:
                      X − µ0
  Test statistic: Z =
                      s n
  α = 0.05
  Rejection region: Z > z0.05 = 1.645
Example – Grade Inflation
Step 3:
                         2.85 − 2.7
  Test statistic:   Z=                = 2.18
                         0.55   64

  p value = P(Z > 2.18) = 0.0146
Step 4:
  Reject H0
Example – Grade Inflation
Step 5:
  The sample data indicates that we are currently
  experiencing grade inflation.

More Related Content

What's hot

PROCEDURE FOR TESTING HYPOTHESIS
PROCEDURE FOR   TESTING HYPOTHESIS PROCEDURE FOR   TESTING HYPOTHESIS
PROCEDURE FOR TESTING HYPOTHESIS Sundar B N
 
Basic of Statistical Inference Part-III: The Theory of Estimation from Dexlab...
Basic of Statistical Inference Part-III: The Theory of Estimation from Dexlab...Basic of Statistical Inference Part-III: The Theory of Estimation from Dexlab...
Basic of Statistical Inference Part-III: The Theory of Estimation from Dexlab...Dexlab Analytics
 
Hypothesis testing1
Hypothesis testing1Hypothesis testing1
Hypothesis testing1HanaaBayomy
 
Estimation and hypothesis testing 1 (graduate statistics2)
Estimation and hypothesis testing 1 (graduate statistics2)Estimation and hypothesis testing 1 (graduate statistics2)
Estimation and hypothesis testing 1 (graduate statistics2)Harve Abella
 
Review & Hypothesis Testing
Review & Hypothesis TestingReview & Hypothesis Testing
Review & Hypothesis TestingSr Edith Bogue
 
HYPOTHESIS TESTING
HYPOTHESIS TESTINGHYPOTHESIS TESTING
HYPOTHESIS TESTINGAmna Sheikh
 
Hypothesis testing , T test , chi square test, z test
Hypothesis testing , T test , chi square test, z test Hypothesis testing , T test , chi square test, z test
Hypothesis testing , T test , chi square test, z test Irfan Ullah
 
Hypothesis Testing
Hypothesis TestingHypothesis Testing
Hypothesis Testingrishi.indian
 
Hypothesis testing
Hypothesis testingHypothesis testing
Hypothesis testingArnab Sadhu
 
Hypothesis and Hypothesis Testing
Hypothesis and Hypothesis TestingHypothesis and Hypothesis Testing
Hypothesis and Hypothesis TestingNaibin
 
hypothesis testing
hypothesis testinghypothesis testing
hypothesis testingilona50
 
Testing Of Hypothesis
Testing Of HypothesisTesting Of Hypothesis
Testing Of HypothesisSWATI SINGH
 
Hypothesis testing
Hypothesis testingHypothesis testing
Hypothesis testingSumit Sharma
 

What's hot (20)

Basics of Hypothesis Testing
Basics of Hypothesis Testing  Basics of Hypothesis Testing
Basics of Hypothesis Testing
 
Hypothesis testing
Hypothesis testingHypothesis testing
Hypothesis testing
 
Testing Hypothesis
Testing HypothesisTesting Hypothesis
Testing Hypothesis
 
PROCEDURE FOR TESTING HYPOTHESIS
PROCEDURE FOR   TESTING HYPOTHESIS PROCEDURE FOR   TESTING HYPOTHESIS
PROCEDURE FOR TESTING HYPOTHESIS
 
Z-test
Z-testZ-test
Z-test
 
Hypothesis Testing
Hypothesis TestingHypothesis Testing
Hypothesis Testing
 
Basic of Statistical Inference Part-III: The Theory of Estimation from Dexlab...
Basic of Statistical Inference Part-III: The Theory of Estimation from Dexlab...Basic of Statistical Inference Part-III: The Theory of Estimation from Dexlab...
Basic of Statistical Inference Part-III: The Theory of Estimation from Dexlab...
 
Hypothesis testing1
Hypothesis testing1Hypothesis testing1
Hypothesis testing1
 
Estimation and hypothesis testing 1 (graduate statistics2)
Estimation and hypothesis testing 1 (graduate statistics2)Estimation and hypothesis testing 1 (graduate statistics2)
Estimation and hypothesis testing 1 (graduate statistics2)
 
Hypothesis testing
Hypothesis testingHypothesis testing
Hypothesis testing
 
Review & Hypothesis Testing
Review & Hypothesis TestingReview & Hypothesis Testing
Review & Hypothesis Testing
 
HYPOTHESIS TESTING
HYPOTHESIS TESTINGHYPOTHESIS TESTING
HYPOTHESIS TESTING
 
Sampling distribution
Sampling distributionSampling distribution
Sampling distribution
 
Hypothesis testing , T test , chi square test, z test
Hypothesis testing , T test , chi square test, z test Hypothesis testing , T test , chi square test, z test
Hypothesis testing , T test , chi square test, z test
 
Hypothesis Testing
Hypothesis TestingHypothesis Testing
Hypothesis Testing
 
Hypothesis testing
Hypothesis testingHypothesis testing
Hypothesis testing
 
Hypothesis and Hypothesis Testing
Hypothesis and Hypothesis TestingHypothesis and Hypothesis Testing
Hypothesis and Hypothesis Testing
 
hypothesis testing
hypothesis testinghypothesis testing
hypothesis testing
 
Testing Of Hypothesis
Testing Of HypothesisTesting Of Hypothesis
Testing Of Hypothesis
 
Hypothesis testing
Hypothesis testingHypothesis testing
Hypothesis testing
 

Viewers also liked

Test of hypothesis
Test of hypothesisTest of hypothesis
Test of hypothesisvikramlawand
 
Hypothesis testing ppt final
Hypothesis testing ppt finalHypothesis testing ppt final
Hypothesis testing ppt finalpiyushdhaker
 
Hypothesis testing; z test, t-test. f-test
Hypothesis testing; z test, t-test. f-testHypothesis testing; z test, t-test. f-test
Hypothesis testing; z test, t-test. f-testShakehand with Life
 
Introduction to Hypothesis Testing
Introduction to Hypothesis TestingIntroduction to Hypothesis Testing
Introduction to Hypothesis Testingjasondroesch
 
Introduction to hypothesis testing ppt @ bec doms
Introduction to hypothesis testing ppt @ bec domsIntroduction to hypothesis testing ppt @ bec doms
Introduction to hypothesis testing ppt @ bec domsBabasab Patil
 
Hypothesis
HypothesisHypothesis
Hypothesis17somya
 
Chapter8 introduction to hypothesis testing
Chapter8 introduction to hypothesis testingChapter8 introduction to hypothesis testing
Chapter8 introduction to hypothesis testingBOmebratu
 
Chap#9 hypothesis testing (3)
Chap#9 hypothesis testing (3)Chap#9 hypothesis testing (3)
Chap#9 hypothesis testing (3)shafi khan
 
Research hypothesis
Research hypothesisResearch hypothesis
Research hypothesisNursing Path
 
Research hypothesis....ppt
Research hypothesis....pptResearch hypothesis....ppt
Research hypothesis....pptRahul Dhaker
 
Week7 lecturestatisticsfordecisionmaking
Week7 lecturestatisticsfordecisionmakingWeek7 lecturestatisticsfordecisionmaking
Week7 lecturestatisticsfordecisionmakingBrent Heard
 
Hypothesis testing
Hypothesis testingHypothesis testing
Hypothesis testingVan Martija
 

Viewers also liked (20)

Test of hypothesis
Test of hypothesisTest of hypothesis
Test of hypothesis
 
Hypothesis testing ppt final
Hypothesis testing ppt finalHypothesis testing ppt final
Hypothesis testing ppt final
 
Hypothesis Testing
Hypothesis TestingHypothesis Testing
Hypothesis Testing
 
Hypothesis
HypothesisHypothesis
Hypothesis
 
Hypothesis testing; z test, t-test. f-test
Hypothesis testing; z test, t-test. f-testHypothesis testing; z test, t-test. f-test
Hypothesis testing; z test, t-test. f-test
 
Introduction to Hypothesis Testing
Introduction to Hypothesis TestingIntroduction to Hypothesis Testing
Introduction to Hypothesis Testing
 
Introduction to hypothesis testing ppt @ bec doms
Introduction to hypothesis testing ppt @ bec domsIntroduction to hypothesis testing ppt @ bec doms
Introduction to hypothesis testing ppt @ bec doms
 
Hypothesis
HypothesisHypothesis
Hypothesis
 
Chapter8 introduction to hypothesis testing
Chapter8 introduction to hypothesis testingChapter8 introduction to hypothesis testing
Chapter8 introduction to hypothesis testing
 
Chap#9 hypothesis testing (3)
Chap#9 hypothesis testing (3)Chap#9 hypothesis testing (3)
Chap#9 hypothesis testing (3)
 
T test
T testT test
T test
 
Research hypothesis
Research hypothesisResearch hypothesis
Research hypothesis
 
Student t-test
Student t-testStudent t-test
Student t-test
 
Research hypothesis....ppt
Research hypothesis....pptResearch hypothesis....ppt
Research hypothesis....ppt
 
Week7 lecturestatisticsfordecisionmaking
Week7 lecturestatisticsfordecisionmakingWeek7 lecturestatisticsfordecisionmaking
Week7 lecturestatisticsfordecisionmaking
 
Two way example
Two way exampleTwo way example
Two way example
 
An introduction to Hypothesis Based Testing
An introduction to Hypothesis Based TestingAn introduction to Hypothesis Based Testing
An introduction to Hypothesis Based Testing
 
FEC 512.05
FEC 512.05FEC 512.05
FEC 512.05
 
Hypothesis testing
Hypothesis testingHypothesis testing
Hypothesis testing
 
Tests of significance
Tests of significance  Tests of significance
Tests of significance
 

Similar to Hypothesis testing an introduction

Top schools in delhi ncr
Top schools in delhi ncrTop schools in delhi ncr
Top schools in delhi ncrEdhole.com
 
hypothesis test
 hypothesis test hypothesis test
hypothesis testUnsa Shakir
 
Testing of Hypothesis, p-value, Gaussian distribution, null hypothesis
Testing of Hypothesis, p-value, Gaussian distribution, null hypothesisTesting of Hypothesis, p-value, Gaussian distribution, null hypothesis
Testing of Hypothesis, p-value, Gaussian distribution, null hypothesissvmmcradonco1
 
Morestatistics22 091208004743-phpapp01
Morestatistics22 091208004743-phpapp01Morestatistics22 091208004743-phpapp01
Morestatistics22 091208004743-phpapp01mandrewmartin
 
Hypothesis Test _One-sample t-test, Z-test, Proportion Z-test
Hypothesis Test _One-sample t-test, Z-test, Proportion Z-testHypothesis Test _One-sample t-test, Z-test, Proportion Z-test
Hypothesis Test _One-sample t-test, Z-test, Proportion Z-testRavindra Nath Shukla
 
Study unit 4 (oct 2014)
Study unit 4 (oct 2014)Study unit 4 (oct 2014)
Study unit 4 (oct 2014)vfvfx
 
Study unit 4 (oct 2014)
Study unit 4 (oct 2014)Study unit 4 (oct 2014)
Study unit 4 (oct 2014)vfvfx
 
Chapter 9 Fundamental of Hypothesis Testing.ppt
Chapter 9 Fundamental of Hypothesis Testing.pptChapter 9 Fundamental of Hypothesis Testing.ppt
Chapter 9 Fundamental of Hypothesis Testing.pptHasanGilani3
 
B.tech admission in india
B.tech admission in indiaB.tech admission in india
B.tech admission in indiaEdhole.com
 
hypothesisTestPPT.pptx
hypothesisTestPPT.pptxhypothesisTestPPT.pptx
hypothesisTestPPT.pptxdangwalakash07
 
Int 150 The Moral Instinct”1. Most cultures agree that abus.docx
Int 150 The Moral Instinct”1.   Most cultures agree that abus.docxInt 150 The Moral Instinct”1.   Most cultures agree that abus.docx
Int 150 The Moral Instinct”1. Most cultures agree that abus.docxmariuse18nolet
 

Similar to Hypothesis testing an introduction (20)

Testing of hypothesis
Testing of hypothesisTesting of hypothesis
Testing of hypothesis
 
Hypothesis
HypothesisHypothesis
Hypothesis
 
Top schools in delhi ncr
Top schools in delhi ncrTop schools in delhi ncr
Top schools in delhi ncr
 
TEST OF SIGNIFICANCE.pptx
TEST OF SIGNIFICANCE.pptxTEST OF SIGNIFICANCE.pptx
TEST OF SIGNIFICANCE.pptx
 
More Statistics
More StatisticsMore Statistics
More Statistics
 
Hypothesis Testing Assignment Help
Hypothesis Testing Assignment HelpHypothesis Testing Assignment Help
Hypothesis Testing Assignment Help
 
hypothesis test
 hypothesis test hypothesis test
hypothesis test
 
Testing of Hypothesis, p-value, Gaussian distribution, null hypothesis
Testing of Hypothesis, p-value, Gaussian distribution, null hypothesisTesting of Hypothesis, p-value, Gaussian distribution, null hypothesis
Testing of Hypothesis, p-value, Gaussian distribution, null hypothesis
 
Morestatistics22 091208004743-phpapp01
Morestatistics22 091208004743-phpapp01Morestatistics22 091208004743-phpapp01
Morestatistics22 091208004743-phpapp01
 
Hypothesis Test _One-sample t-test, Z-test, Proportion Z-test
Hypothesis Test _One-sample t-test, Z-test, Proportion Z-testHypothesis Test _One-sample t-test, Z-test, Proportion Z-test
Hypothesis Test _One-sample t-test, Z-test, Proportion Z-test
 
7 hypothesis testing
7 hypothesis testing7 hypothesis testing
7 hypothesis testing
 
Study unit 4 (oct 2014)
Study unit 4 (oct 2014)Study unit 4 (oct 2014)
Study unit 4 (oct 2014)
 
Study unit 4 (oct 2014)
Study unit 4 (oct 2014)Study unit 4 (oct 2014)
Study unit 4 (oct 2014)
 
Chapter 9 Fundamental of Hypothesis Testing.ppt
Chapter 9 Fundamental of Hypothesis Testing.pptChapter 9 Fundamental of Hypothesis Testing.ppt
Chapter 9 Fundamental of Hypothesis Testing.ppt
 
B.tech admission in india
B.tech admission in indiaB.tech admission in india
B.tech admission in india
 
Formulatinghypotheses
Formulatinghypotheses Formulatinghypotheses
Formulatinghypotheses
 
hypothesisTestPPT.pptx
hypothesisTestPPT.pptxhypothesisTestPPT.pptx
hypothesisTestPPT.pptx
 
Int 150 The Moral Instinct”1. Most cultures agree that abus.docx
Int 150 The Moral Instinct”1.   Most cultures agree that abus.docxInt 150 The Moral Instinct”1.   Most cultures agree that abus.docx
Int 150 The Moral Instinct”1. Most cultures agree that abus.docx
 
Hypothesis testing
Hypothesis testingHypothesis testing
Hypothesis testing
 
Hypothesis testing
Hypothesis testingHypothesis testing
Hypothesis testing
 

Recently uploaded

Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoffsammart93
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)wesley chun
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsJoaquim Jorge
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUK Journal
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century educationjfdjdjcjdnsjd
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processorsdebabhi2
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
Evaluating the top large language models.pdf
Evaluating the top large language models.pdfEvaluating the top large language models.pdf
Evaluating the top large language models.pdfChristopherTHyatt
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Servicegiselly40
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 

Recently uploaded (20)

Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
Evaluating the top large language models.pdf
Evaluating the top large language models.pdfEvaluating the top large language models.pdf
Evaluating the top large language models.pdf
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 

Hypothesis testing an introduction

  • 2. Topics Steps in a hypothesis test. Large sample tests for µ: two-tail. Large sample tests for µ: one-tail. Type I and Type II errors.
  • 3. Section 7.4 Steps in a Hypothesis Test
  • 4. Definitions In statistics, a hypothesis is an idea, an assumption, or a theory about the characteristics of one or more variables in one or more populations. A hypothesis test is a statistical procedure that involves formulating a hypothesis and using sample data to decide on the validity of the hypothesis.
  • 5. Definitions (cont.) The null hypothesis is a statement about a parameter of the population. It is labeled H0. The alternative hypothesis is a statement about a parameter of the population that is opposite to the null hypothesis. It is labeled HA. A test statistic is a number that captures the information in the sample data. It is used to decide between the null and alternative hypotheses.
  • 6. Definitions (cont.) The significance level, α, is the maximum probability tolerated for rejecting a true null hypothesis. The p value is the probability of a more extreme departure from the null hypothesis than the observed data.
  • 7. Definitions (cont.) The rejection region is the range of values of the test statistic that will lead us to reject the null hypothesis. It is defined by the critical value. The area of the rejection region is α, the significance level.
  • 8. Goals To understand the difference between estimation and testing. To learn the 5 steps involved in a hypothesis test.
  • 9. Estimation Versus Testing Estimation is the process of providing a numerical value (point) or values (interval) for a population parameter based on information in a sample. Testing is a procedure for assessing whether sample data are consistent with statements (hypotheses) made about the population.
  • 10. Steps Step 1: Set up the null and alternative hypotheses. Step 2: Define the test procedure (includes selecting a test statistic, an α level and a rejection region). Step 3: Collect the data and calculate the test statistic and the p value. Step 4: Decide whether to reject the null hypothesis.
  • 11. Steps (cont.) Step 5: Interpret the results in the context of the problem.
  • 12. Section 7.6 Large-Sample Test of the Mean: Two-Tail Tests
  • 13. Definitions A large-sample test of the mean is conducted when the characteristic of interest is the population mean, µ, and either of these situations exists: the population standard deviation, σ, is known (regardless of sample size) the population standard deviation, σ, is unknown but n ≥ 30
  • 14. Definitions (cont.) A two-tail test of the population mean has these null and alternative hypotheses: H0: µ = [specified number] HA: µ ≠ [specified number]
  • 15. Goal To apply the 5 steps of a hypothesis test to a two-tail test of a population mean, µ, based on information in a large sample (n ≥ 30).
  • 16. Example – Humerus Bones Humerus bones from the same species of animal tend to have approximately the same length-to-width ratios. For a particular species (Species A) the mean ratio is 8.5. Suppose 41 fossils of humerus bones of an unknown species were unearthed at an archeological site.
  • 17. Example – Humerus Bones Suppose the length-to-width ratios of the 41 fossils were calculated. It is believed (hypothesized) that this site was not populated by Species A.
  • 18. Example – Humerus Bones Step 1: Set up the null and alternative hypotheses. Let µ = the mean ratio for the site. H0: was populated by Species A H0: µ = 8.5 HA: was not populated by Species A HA: µ ≠ 8.5
  • 19. Example – Humerus Bones Step 2: Define the test procedure. X − µ0 Consider as our test statistic Z= s n where µ0 = 8.5 This measures the distance of between the mean ratio of the sample and the mean for Species A. We should reject H0 for large values of |Z|.
  • 20. Example – Humerus Bones Consider as our rejection region |Z| > z. This means we reject H0 if Z > z or Z < -z. We need to choose z so that α = P(reject a true H0) = P(Z > z) + P(Z < -z), assuming µ = 8.5 If H0 is true then Z ~ N(0,1).
  • 21. Example – Humerus Bones α/2 α/2 -z 0 z = -zα/2 = zα/2
  • 22. Example – Humerus Bones So we reject H0 if |Z| > zα/2 Equivalently, reject H0 if Z > zα/2 or Z < -zα/2 Let’s choose α = 0.05 zα/2 = z.025 =1.96 Reject H0 if Z > 1.96 or Z < -1.96
  • 23. Example – Humerus Bones Step 3: Collect the data and calculate the test statistic and the p value. For the n = 41 ratios we have X = 9.258 and s = 1.404 9.258 − 8.5 Z= = 3.46 1.404 41
  • 24. Example – Humerus Bones p value = P(|Z| > |3.46|) = P(Z > 3.46) + P(Z < -3.46) = 2P(Z < -3.46) = 2(.0003) = 0.0006
  • 25. Example – Humerus Bones Step 4: Decide whether to reject the null hypothesis. Z = 3.46 Rejection region: Z > 1.96 or Z < -1.96 Reject H0: µ = 8.5 Accept HA: µ ≠ 8.5
  • 26. Example – Humerus Bones Step 5: Interpret the results in the context of the problem. The fossils found at the site are not consistent with those that would come from Species A. Hence, the site was not populated by species A.
  • 27. p Value Versus α The p value is the smallest value of α for which we could reject H0. If p value < α then reject H0. If p value ≥ α then do not reject H0. A p value can be used in place of a rejection region.
  • 28. Example – Humerus Bones α = 0.05 p value = 0.0006 p value < α Reject H0: µ = 8.5
  • 29. Section 7.7 What Error Could You Be Making?
  • 30. Definitions A Type I error is made when we reject the null hypothesis and the null hypothesis is actually true. A Type II error is made when we fail to reject the null hypothesis and the null hypothesis is actually false. The probability of making a Type I error is labeled α. The probability of making a Type II error is labeled β.
  • 31. Goal To learn from our mistakes.
  • 32. Truth versus Decision Truth Decision H0 true HA true Believe H0 Right choice Type II error Believe HA Type I error Right choice
  • 33. Example – Humerus Bones H0: site was populated by Species A H0: µ = 8.5 HA: site was not populated by Species A HA: µ ≠ 8.5 Type I error = conclude the site was not populated by Species A when it actually was.
  • 34. Example – Humerus Bones Type II error = conclude the site was populated by Species A when it actually was not.
  • 35. Choosing α So far our hypothesis tests allow us to choose α. In many (but not all) applications a Type I error is more costly than a Type II error. As α decreases, β increases. As β decreases, α increases. Whichever error is the most costly is the probability of which you need to minimize.
  • 36. Example – Humerus Bones Suppose it would be most embarrassing to claim that the site was not populated by Species A when it actually was. Make α small (α = 0.01). Suppose it would cost you your academic career to say that the site was populated by species A when it actually was not. Make β small (α = 0.10).
  • 37. Reject H0 Versus Don’t Reject H0 Clearly, if we reject H0 then we accept HA. However, if we do not reject H0 does this imply that we accept H0? No. At least not in this class. Type I error = reject a true H0 P(Type I error) = α (known) Type II error = accept a false H0 P(Type II error) = β (unknown, for now)
  • 38. Reject H0 Versus Don’t Reject H0 Since we know α we will allow ourselves the risk of rejecting H0 when H0 is true. However, since we do not know β we will not risk accepting H0 when H0 is false. If we do not reject H0 we will conclude that there is insufficient evidence in the sample to say H0 is false.
  • 39. Section 7.8 Which Theory Should Go into the Null Hypothesis?
  • 40. Definitions A two-tail test of the population mean has these null and alternative hypotheses: H0: µ = µ0 HA: µ ≠ µ0 A lower-tail test of the population mean has these null and alternative hypotheses: H0: µ ≥ µ0 HA: µ < µ0
  • 41. Definitions (cont.) An upper-tail test of the population mean has these null and alternative hypotheses: H0: µ ≤ µ0 HA: µ > µ0
  • 42. Two-Tail Tests H0: µ = µ0 H A : µ ≠ µ0 HA: µ > µ0 or µ < µ0 In these cases we wish to show that the mean is not some specified value (research hypothesis). With this end, we assume the complement to be true (H0) until we have sufficient evidence to reject H0 (accept HA).
  • 43. Example – Humerus Bone µ = mean ratio for the site HA: µ ≠ 8.5 HA: µ < 8.5 or µ > 8.5 H0: µ = 8.5
  • 44. Lower-Tail Tests H0: µ ≥ µ0 H A : µ < µ0 In these cases we usually wish to show that the mean is less than some specified value (research hypothesis). With this end, we assume the complement to be true (H0) until we have sufficient evidence to reject H0 (accept HA).
  • 45. Example – Vending Machine µ = average amount of beverage dispensed into a 12 ounce cup You believe that you are being ripped off by this vending machine, i.e., µ < 12 ounces. HA: µ < 12 ounces H0: µ ≥ 12 ounces
  • 46. Upper-Tail Tests H0: µ ≤ µ0 H A : µ > µ0 In these cases we usually wish to show that the mean is greater than some specified value (research hypothesis). With this end, we assume the complement to be true (H0) until we have sufficient evidence to reject H0 (accept HA).
  • 47. Example – Grade Inflation µ = 2004-05 GPA at UCF The historical average is 2.7 Suppose you wish to show that UCF is currently experiencing grade inflation, i.e., µ > 2.7 HA: µ > 2.7 H0: µ ≤ 2.7
  • 48. Section 7.9 One-Tail Tests of the Mean: Large Sample
  • 49. Lower-Tail Test H0: µ ≥ µ0 versus HA: µ < µ0 X − µ0 Test statistic: Z = s n Rejection region: Z < z α = P(Z < z), given H0 true
  • 50. α 0 z = -zα
  • 51. Lower-Tail Test z = -zα Rejection region: Z < -zα p value = P(Z < observed Z)
  • 52. Upper-Tail Test H0: µ ≤ µ0 versus HA: µ > µ0 X − µ0 Test statistic: Z = s n Rejection region: Z > z α = P(Z > z), given H0 true
  • 53. α 0 z = zα
  • 54. Upper-Tail Test z = zα Rejection region: Z > zα p value = P(Z > observed Z)
  • 55. Example – Grade Inflation µ = 2004-05 GPA at UCF The historical average is 2.7 Suppose you wish to show that UCF is currently experiencing grade inflation. Suppose that from a sample of 64 students we had an average GPA of 2.85 with a standard deviation of 0.55.
  • 56. Example – Grade Inflation Let the Type I error be 0.05. Step 1: HA: µ > 2.7 H0: µ ≤ 2.7 Step 2: X − µ0 Test statistic: Z = s n α = 0.05 Rejection region: Z > z0.05 = 1.645
  • 57. Example – Grade Inflation Step 3: 2.85 − 2.7 Test statistic: Z= = 2.18 0.55 64 p value = P(Z > 2.18) = 0.0146 Step 4: Reject H0
  • 58. Example – Grade Inflation Step 5: The sample data indicates that we are currently experiencing grade inflation.