Errors in Hypothesis Tests

Download Report

Transcript Errors in Hypothesis Tests

Errors in Hypothesis Tests
When you perform a hypothesis
test you make a decision:
reject H0 or fail to reject H0
When you make
one of these
decisions, there is
a possibility that
you could be wrong!
That you made an
error!
There are two decisions
that we make; reject or
fail to reject. Each could
possibly be a wrong
decision; therefore, there
are two types of errors.
Type I error
• When you reject the null
hypothesis that is really true
• Denoted by a
– Is the level of significance of
the test
a
m0
Type II error
• When you fail to reject the
null hypothesis when it is false
• Denoted by b
Fail to reject
Reject
a
b
Type I –
reject a
The true
x-barHis0 really
The x-bar is really
part of the H
part of the Ha curve,0
curve, but we
but we mistake it as
mistake it as being
being part of the H0
Type part
II – of the Ha
curve
fail to curve
reject a
false H0
H0
True
H0
False
Reject Type I
Correct
error a
Fail to
reject
Type
II
Correct
error
btrue
Suppose
Suppose
H H
is H
Suppose
is is
0
0
0
Suppose
H
is
true
0 reject
&false
we
false
fail
&
to
we
& we failreject
to
&
we
reject
it,
it,
it,
what
what
type
type
of of
reject
it,
what
whatwas
type
of
decision
made?
was
typedecision
of decision
decision
was
was made?
made?
made?
How do we word statements
of type I & type II errors?
“We decide this decision
when in reality this is true.”
You replace the
red, underlined
words with words
from context!
Consequences – are NOT the
definitions of type I & II
errors.
They are what happens as a
result of making that
incorrect decision.
I - that is why
there
ConsiderType
a murder
trial:
What
must be evidence beyond a
reasonable doubt! We
H0:don’t
defendant is
arewant
the to
hypotheses?
send innocent people
innocent to
jail!
Ha: defendant is guilty
Type I error –Decide the defendant is guilty when really innocent
Consequence: An innocent person goes to prison
Which of these errors does our society believe to
be worse?
Type II error – Decide defendant is not guilty when really guilty
Consequence: A guilty person goes free
Facts:
As a
As a you
increases,
• Every time you make a decision,
b
have potentially made an decreases,
error.
bdecreases
increases
• a & b are inversely related
Fail to reject H0
Reject H0
a
m0
b
ma
Facts continued:
• The seriousness of the error types is
determined by the specific situations.
– Depending upon the situation type I or
type II may be the more serious.
• We often DO NOT know if
an error
Someone
made
an error with
is made in real life.
– Except for cases like
• Firestone tires
• Drugs like: Phen-phen & Vioxx
these
products
Lay’s Chip Company decides to accept a
truckload of potatoes based upon
results from a sample of potatoes
from the truckload.
What are the hypotheses?
H0: potatoes good
Ha: potatoes bad
Type I error?Decide the potatoes are bad when they really are
good
they really
Type II error? Decide the potatoes are good whenSometimes,
are bad
the
seriousness
From the supplier’s viewpoint,
depends upon
A
type
I
error
which is more serious?
the person’s
point-of-view
From the chip company’s viewpoint,
which is more serious? A type II error
Water samples are taken from water used for
cooling as it is being discharged from a power plant
into a river. It has been determined that as long as
the mean temperature of the discharged water is at
most 150 degrees F, there will be no negative
effects on the river’s ecosystem. To investigate
whether the plant is in compliance with
regulations that prohibit a mean discharge
above 150 degrees F, fifty water samples
will be taken at randomly selected times, and
Type I :
the temperature of each sample recorded.
Type II:
Decidewould
the agree
H0: m =Most
150 people
Decide
temperature
is
What are the hypotheses?
that the
type the
II error
Ha: m >150 temperature
above
150°
would be
more
serious
isn’t
above
150°
What are the Type I and II errors?
when
it’s really
because
it would
when
it’s
really
below.
endanger
the
river’s
Which is more serious?
above.
A doctor is considering a new
medication to help fight infections.
However, the medication has the
possibility of being highly toxic to
the patient. You will test the
medication to determine toxicity.
H : medicine is not
0
What are the hypotheses?
What are the Type I
& II errors?
toxic
Ha: medicine is toxic
Type I: decide
medicine is toxic
when it really isn’t
Type II : decide medicine isn’t
toxic when it really is
Which is more serious?
Most would consider a type II
error more serious since
people could be harmed.
A government agency has received
numerous complaints that a particular
restaurant has been selling underweight
hamburgers. The restaurant advertises
that it’s patties are “a quarter pound” (4
ounces).
Identify the following decisions:
Correct
decision!
We decide the mean weight of
hamburgers is less than 4 ounces when in
fact they really are less.
A government agency has received
numerous complaints that a particular
restaurant has been selling underweight
hamburgers. The restaurant advertises
that it’s patties are “a quarter pound” (4
ounces).
Identify the following decisions:
Type II
error
We decide the mean weight of
hamburgers is not less than 4 ounces
when in fact they really are less.
How does one decide what
a level to use?
After assessing the
consequences of type I and type
II errors, identify the largest a
that is tolerable for the
problem. Use that a level for
your level of significance.
Power of a test
The power of a test (against
a specific alternative value)
• Is the probability that the test
will reject the null hypothesis
when the alternative is true
• In practice, we carry out the test
in hope of showing that the null
hypothesis is false, so high power
is important
Suppose H0 is false –
Suppose
H
is
false
–
We
correctly
reject
a
0
what if we decide to
whatreject
if weHit?
decide
false
Hto
0!
0
fail to reject True
it?
H0
False
Suppose H0 is
Reject Type I Correct
true – what if
we decide to
a
Power
fail
to
reject
Fail to Correct
Suppose H0 is true – Type IIit?
reject
b
what if we decide to
reject it?
A researcher selects a random sample of size
49 from a population with standard deviation
s = 35 in order to test at the 1% significance
level the hypothesis:
H0: m = 680
Ha: m > 680
What is the probability of committing a Type
I error?
a = .01
H0: m = 680
Ha: m > 680
For what values of the sample mean would
you reject the null hypothesis?
Invnorm(.99,680,5) =691.63
H0: m = 680
Ha: m > 680
If H0 is rejected, suppose that ma is 700.
What is the probability of committing a
Type II error?
Normalcdf(-10^99,691.63,700,5) =.0471
What is the power of the test?
Power = 1 - .0471 = .9529
H0: m = 680
Ha: m > 680
If H0 is rejected, suppose that ma is 695. What
is the probability of committing a Type II
error?
Normalcdf(-10^99,691.63,695,5) =.2502
What is the power of the test?
Power = 1 - .2502 = .7498
Fail to Reject H0
Reject H0
a
m0
Power = 1 - b
b
ma
What happens to a, b, & power
when the sample size is increased?
Fail to Reject H0
Reject H0
a
m0
b
ma
Facts:
• The researcher is free to determine the
value of a.
• The experimenter cannot control b, since it
is dependent on the alternate value.
• The ideal situation is to have a as small as
possible and power close to 1. (Power > .8)
• As a increases, power increases. (But also
the chance of a type I error has
increased!)
• Best way to increase power, without
increasing a, is to increase the sample size