MODULE 9 : HYPOTHESIS TESTING
• INTRODUCTION
• HYPOTHESIS TEST DEFINED
• ONE-SIDED AND TWO SIDED TEST
• TYPE 1 AND TYPE 2 ERROR
• TERMINOLOGIES
MOD9 Page 1
INTRODUCTION
Setting up and testing hypothesis is an essential part of statistical inference. In order to formulate such a test, usually a
theory is put forward, either because it is believed to be true or because it is to be used as basis for argument, but has not
been proved
In each problem considered, the question of interest is simplified into two competing claims. "hypotheses between which
we have a choice; the null hypothesis, denoted by Ho, and the alternative hypothesis denoted by Ha. These two competing
claims/hypotheses are not: however, treated on an equal basis. Special consideration is given to the null hypothesis. We
have two common situations.
1. The experiment has carried out in an attempt to disprove Or reject a particular hypothesis, the null hypothesis, thus we
give that one priority so that it cannot be rejected unless the evidence against it
is sufficiently wrong.
Example:
Ho: There is no difference in taste between the regular coke and the diet coke.
Ha: There is a difference in taste between the regular coke and the diet coke.
2. If one of the two hypotheses is simpler, we give it priority So that a more complicated theory is not adapted unless there is
sufficient evidence against the simpler one. For example. it is "simpler" to claim that there is no difference in flavor between
the regular coke and the diet coke than it is to say that there is a difference.
The hypotheses are often statements about population parameters showing information like expected values and variances.
The outcome of a hypothesis testing, therefore, results in either accepting the Ho or rejecting the Ho.
MOD9 Page 2
HYPOTHESIS TEST DEFINED
A hypothesis test is a procedure to determine the assertion about characteristics of a population as to its acceptability and Reasonableness
Hypothesis Testing
Hypothesis testing often confuses people, but is the keynote of statistical applications. In fact, acceptance sampling test, designed
experiment, and control is classified as statistical hypothesis test
1. Statistical tests separate significant effects from mere luck of random chance.
2. All hypothesis tests have an unavoidable, but quantifiable risks of making the wrong conclusion. Statistical tests always involve Type I
(alpha error) and Type II (beta error) risks. The Type I risk is the chance of deciding that a significant effect is present when it is not. The
Type II risk is the chance
of not detecting a significant effect when one exists.
Null Hypothesis and Alternative Hypotheses
The null hypothesis (Ho) represents a theory that has been put forward, either because it is believed to be true or because it is to be used
as a basis for argument, but has not yet been proven. For example, in a clinical trial Of a new drug, the null hypothesis might be that the new
drug is no better, on the average, than the current drug. We would write the null hypothesis as; Ho: There is no difference between the two
drugs on the average.
We give special consideration to the null hypothesis. This is due to fact that the null hypothesis relates to the statement being tested,
Whereas, the alternative hypothesis relates to the statement to be accepted if and when the null hypothesis is rejected
The alternative hypothesis (Ha) is a statement of what a statistical hypothesis test is set up to establish. For example, in a clinical trial of a
new drug. the alternative hypothesis might be that the new drug has a different effect, on the average. compared to that of the current drug.
We would write; Ha: The two drugs have different effects, on the average.
MOD9 Page 3
The alternative hypothesis might also be that the new drug is better ,on the average. than the current drug. In this case,
we would write:
Ha: The drug is better than the current drug on the average
Every statistical test tests the null hypothesis (Ho) against the alternative hypothesis (Ha). Null means "nothing" and the
null is that nothing is present. The process change or treatment makes no difference. or the process is operating properly.
The Null Hypothesis is like presumption of innocence.
Accepting the Null hypothesis is acquitting a defendant. It does not prove that the null hypothesis is true of that the
defendant is innocent. It means that there is reasonable doubt about the defendant guilt. In statistical testing, the
significance level, Type 1 risk. or alpha risk is the "reasonable doubt". It is the chance of wrongly rejecting the null
hypothesis when It is true. In acceptance sampling, it is the risk of wrongly rejecting a lot that meets requirements.
The alternative hypothesis is that process change or treatment has an effect. or something is wrong with the process. The
Type II risk is the chance of accepting ng the null hypothesis when it is false. The Type II risk is an acceptance of a plan. It
is the chance of passing a lot that does not meet the requirements. If the Type 1 risk is the chance of crying wolf while the
Type 11 risk is the chance of not seeing a real wolf.
The final conclusion Once the test has been carried out is always given in terms of the null We either "reject Ho" in favor
of Ha or "do not reject Ho"; we never conclude "reject Ha" or even "accept Ha".
If we conclude "do not reject Ho", this does not necessarily mean that the null hypothesis is true. It only suggests that
there is no sufficient evidence against Ho in favor of Ha. Rejecting the null hypothesis then. suggests that the alternative
hypothesis maybe true
MOD9 Page 4
ONE-SIDED AND TWO-SIDED TESTS
A. One-Sided Test
A one-sided test is a statistical hypothesis test in which the values for which we can reject the null hypothesis. Ho are located
entirely in one tail of the probability distribution.
In other words, critical region for one-sided test is the set of value less than the critical value of the test or set of values
greater than the critical value of the test
A one-sided test is also to as a one tailed test of significance
Example:
Suppose we wanted to test a manufacturers claim that there are on average 50 matches in a box. We set up the following
hypothesis
Ho : μ= 50 against Ha: μ< 50 or Ha : > SO
Either of these two alternative hypothesis (Ha) would lead to a one sided test. Presumably, we would want to test the null
hypothesis against the first alternative hypothesis since it would be useful to know that there is likely to be less than 50
matches on the average in a box.
Another alternative hypothesis could be tested against the same null leading this time to a two -sided test
Ho: μ=50 against Ha: μ≠50
That is, nothing specific can be said about the average number of
Matches in a box, only that. if we could reject the null hypothesis in our test we would know that the average of matches In a
is likely to be less than or greater than 50.
MOD9 Page 5
B. TWO-SIDED TEST
A probability computed considering differences in both directions is called a "two-tailed" probability. The name makes
sense both tails of the sampling distribution are considered. There are situations in which an experimenter is concerned
only with the differences in one direction.
For example. an experimenter may be concerned with whether or not μ1 = μ2 is greater than zero. However.μ1 = μ2 is not
greater than zero, the experimenter may not care whether it equals zero or less than zero
For Instance. if a new drug treatment is develop , main issue is whether not it is better than a placebo. If the treatment is
not better than a placebo, then it will not be used. It does not realty matter whether or not it is worse than the placebo.
only one direction is of concern to an experimenter, then a "one—tailed" test can be performed If an experimenter is
only concerned with whether or not μ1 = μ2 is greater than zero. then one-tailed test would involve calculating the
probability of obtaining a value that is greater than the one obtained in the experiment
A two-sided test is a statistical hypothesis test in which the values for which we can reject the null hypothesis, Ho are
located in both tails of the probability distribution. In other words. The critical region for a two-Sided test is the of
values less than a first critical value of the test and the set of values greater than a second critical value Of the test . A
sided is also referred to as a of significance.
MOD9 Page 6
TYPE I AND TYPE II ERRORS
There are two kinds of errors that be made in. Significance testing
1. a true null hypothesis can be incorrectly rejected and
2. a false null hypothesis can fail to be rejected..
The former error is called a Type I error and the latter error called a Type Il error. These two types of errors is defined in
the table . The probability of I error is designated by the Greek letter alpha ( ) and is called the Type I error rate; the
probability Of Type Il error (the Type Il error rate) is designated by Greek letter beta ( . A Type Il error is only an error
in the sense that an opportunity to reject the null hypothesis correctly is lost. It is not an error in the sense that an
incorrect conclusion is drawn since no conclusion is drawn when the null hypothesis is not rejected.
Statistical Decision True State Null Hypothesis
Ho: True Ho: False
Reject Ho Type I Error Correct
Do not reject Ho Correct Type II error
MOD9 Page 7
A. Type 1 Error
A Type I error is an error in every sense of the word, A conclusion is drawn that the null hypothesis is false when in fact it
is true. Therefore Type I error are generally considered more serious than Type Il errors. The probability of I error is
called the significance level and is set by the experimenter.
There is a tradeoff between Type I and Type Il errors. The more an experimenter protects himself against these errors by
choosing a low level, the greater the chance of committing a Type Il error. Requiring a very strong to reject null
hypothesis makes it very unlikely .
That a true null hypothesis will not be rejected . However ,it increases the chance that a false null hypothesis will not be
rejected. The type 1 error rate is almost always set at 0.05 or0.01; the latter being more conservative since it requires
strong evidence to reject the null hypothesis at 0.01 level than 0.05 level.
In an hypothesis test a type 1 error occurs when the null hypothesis is rejected when it is in fact true, that is HO, is wrongly
rejected. For example in clinical trial of a new drug , the null hypothesis might be that new drug is no better , on the
average ,than the current drug, That is HO: There is no difference between the two drugs on the average. A type 1 error
would occur if we concluded that the two drugs produce different effect when in fact there is no difference between them.
A type I error is often considered to be more serious and therefore more important to avoid than a type 11 error . The
hypothesis test procedure is therefore adjusted so that there is a guaranteed " low probability of rejecting the null
hypothesis wrongly . This probability is using the formula
= =
MOD9 Page 8
B. Type Il Error
In a hypothesis test. a Type Il error occurs the null hypothesis Ho. is not rejected when in fact false. For example, in a clinical
trial of a new drug, the null hypothesis might be that the new drug is no on average, than the current drug. that is, Ho: There
is no difference between the two drugs on average A Type Il error would occur it was concluded that the two drugs produced
the same effect, that is, there is no difference between the two drugs on average, when in fact they produced different ones.
The exact probability of a Type Il error is generally unknown. If we do not reject the null hypothesis, it may still be false (a
Type Il error) as the sample may not be big enough to identity the falseness of the null hypothesis (especially if the truth is
very close to hypothesis). A Type Il error is frequently due to choosing too small sample Sizes.
The probability Of Type Il error is symbolized by ( ) and written as:
P (Type Il error ) = ( but is generally unknown )
MOD9 Page 9
HYPOTHESIS TESTS TERMINOLOGIES
To get started, there are terms to and assumptions, to
Significance Level
The significance level which is usually denoted by alpha ( ) is related to the degree of certainty you require in order to reject
the in of the hypothesis. By taking a small sample you cannot be certain about your conclusion. so, you decide in advance to
reject the null hypothesis if of observing your Sampled is than the For a significance level of 5%. the notation is a = 0.05. For
this significance level. the probability Of incorrectly rejecting the null hypothesis when it is actually true 5% . If you need more
protection from this error a lower value of .
P-Value
The P-Value is the probability of observing the given sample result under the assumption that the null hypothesis is true. If the
P-value is less than the alpha, Then you reject the null hypothesis . For example if alpha =0.05 and p-value is 0.03. then you
reject the null hypothesis.
Test statistic
A test statistic is a quantity calculated from the "sample data". Its value is used to decide whether or not the null hypothesis
should be rejected in a hypothesis test. The choice of the test statistic will depend on the assumed probability model and the
hypotheses under question.
Critical value's
The critical value(s) for a hypothesis test is a threshold to which the value of the test statistic in a sample is compared to
determine whether or not null hypothesis is rejected
Critical region
The critical region or rejection region, is a set of values of the test statistic for which null hypothesis/s is rejected in a
hypothesis test, that is, the sample space for the test statistic is partitioned into regions; the critical region will lead us to reject
the null hypotheses, the other not. Therefore. if the observed values of the test statistic is a member of the critical region,
conclude "reject Ho", if it is not a member Of the critical region then can conclude "do not reject Ho"
MOD9 Page 10