0% found this document useful (0 votes)
22 views54 pages

Hypothesis Testing

Uploaded by

Aidan Ramos
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
22 views54 pages

Hypothesis Testing

Uploaded by

Aidan Ramos
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 54

HYPOTHESIS TESTING

Hypothesis Testing
It is the process of making an inference
or generalization on a population based
on the results of the study on samples.
It is an act in statistics whereby an
analyst tests an assumption regarding a
population parameter.
It is used to assess the plausibility of a
hypothesis by using sample data.
Statistical Hypothesis
It refers to a guess or
prediction made by a
researcher regarding the
possible outcome of the
study.
Two Types of Statistical Hypothesis

1.Null Hypothesis (Ho)


It is the hypothesis to be tested which one hopes to reject.
It shows equality or no significant difference or relationship
between variables.
2. Alternative Hypothesis (Ha or H1)
 It generally represents the idea which the researcher wants to prove.
 It shows inequality or significant difference or relationship between
variables.
 One group is superior to the other or one group is better than the other.
 One group is inferior to the other.
Note: In doing a research, the first thing you should have is a
research problem. From there, you can formulate the null and
alternative hypotheses.

Example:
Problem: Performance in Mathematics of the First-born
and Last-born Children
In this problem, you are comparing the performance
in Mathematics of two (2) groups, namely:
A. the first-born children; and
B. the last-born children.
Since the null hypothesis always shows non-significance of
difference between the groups being compared, then it should
be stated in the following manner:
Ho: There is no significant difference in the performance in
Mathematics between the first-born and last-born children.

After stating the null hypothesis, the alternative hypothesis


can be formulated. It should be the opposite of the null
hypothesis. In the above problem, the alternative hypothesis
should be stated as follows:
H1: There is a significant difference in the performance in
Mathematics between the first-born and last-born children.

Note: The way the alternative hypothesis is stated determines the type of
hypothesis test to be used. If the null hypothesis is rejected, the alternative
hypothesis is accepted, and if the null hypothesis is accepted, it follows that the
alternative hypothesis is rejected. For this reason, all possible values of the
population parameter which are not included in the null hypothesis should be
included in the alternative hypothesis. Rejection of the null hypothesis means
it is wrong, while acceptance of the null hypothesis does not mean it is
true, it means that we do not have enough evidence to reject it. We may
have an insufficient number of samples or there is an error in sampling, or some
restrictions or the test used were not followed.
Types of Hypothesis Testing
A.One-tailed Test or One-directional test
It is a directional test with the region of rejection lies
on either left or right tail of the normal curve.
1. Right directional Test
 The region of rejection is on the right tail.
 It is used when the alternative hypothesis uses
comparatives such as greater than, higher than,
better than, superior to, exceeds, etc.
Ho: µ1 =µ2 or Ho: p1=p2
H1: µ1 > µ2 H1: p1>p2
2. Left directional Test
 The region of rejection is on the left tail.
 It is used when the alternative hypothesis
uses comparatives such as less than, smaller
than, inferior to, lower than, below, etc.

Ho: µ1=µ2 or H o: p1=p2


H1: µ1<µ2 H1: p1<p2
B. Two-tailed test or Non-directional Test
It is a non-directional test with the regions of rejection lie
on both tails of the normal curve.
It is used when the alternative hypothesis uses words
such as not equal to, significantly different, etc.

Ho: µ1=µ2 or H1: µ1≠µ2

Ho: p1=p2 H1: p1≠p2


Using the given research problem, let us illustrate the
different alternative hypotheses according to the interest of the
researcher.
Problem: Performance in Mathematics of the First-born and the Last-
born Children

If the researcher feels that the first-born children perform better in


Mathematics than the last-born children, then the null and alternative
hypotheses could be stated as:
Ho: The first-born children perform equally well in mathematics as the
last-born children.
H1: The first-born children perform better in mathematics than the last-
born children.
Notice that the null hypothesis implies that the first-
born children’s performance is just the same as the
performance of the last-born. In other words, their
performances in mathematics are equal.

The alternative hypothesis requires a one-tailed test,


right directional hypothesis test. The advantage of this
test over the non-directional test is that, in case the null
hypothesis is rejected, we know which one of the two
groups is superior to the other.
If the researcher just wants to know if there is a
significant difference in their performance, then the
null and the alternative hypotheses could be stated
as follows:
Ho: There is no significant difference in the performance in
Mathematics between the first-born and last-born children.
H1: There is a significant difference in the performance in
Mathematics between the first-born and last-born children.
Like in the previous example, the null hypothesis shows equality of their
performance, and the alternative hypothesis implies that they are not
equal. This type of alternative hypothesis requires a two-tailed or non-
directional hypothesis test. The disadvantage of this is that, in case
the null hypothesis is rejected, we will not be able to tell which group
performs better. The only information we can get is that they perform
differently in Mathematics.

To avoid confusion in writing the hypothesis, just remember the


following:
 The null hypothesis (Ho) always expresses equality (=).
 The alternative hypothesis (H1) can be expressed in the
form which involves <, > or ≠
Statistical Errors in Hypothesis Testing
We always make decisions about the population, based on
samples and the results of the test on H o. Since, we use samples
to make an inference about the population, we sometimes commit
errors.
Two Types of Statistical Errors
1.Type I error
It is committed when the null hypothesis is
rejected when in fact it is True and the alternative
hypothesis is False. It is also called false-
positive.
2. Type II error
It is committed when the null hypothesis is accepted
when in fact it is False and the alternative hypothesis
is True. It is also called false-negative.
Decision
Facts Accept Ho Reject Ho
Ho is True Correct decision Type I Error
Ho is False Type II error Correct decision
The two types of errors could be further illustrated using the
following example:
“Maria has two suitors, Ricardo and William. Ricardo showers
her with gifts, takes her out every weekend for lunch, and is always at
her side. On the other hand, William visits her occasionally, gives her
gifts only when there are special occasions, and never brought her
out to dine. Maria’s conservative family believes that William is a good
choice; however, she feels otherwise.”

 If Maria rejects Ricardo when he is really a good man,


then she commits a Type I error.
 However, if Maria accepts William when in fact, he is
not good, she commits a Type II error
Level of Significance of a Test
The probability of committing a Type I error is
designated by alpha (α).
The probability of committing a Type II error is
designated by beta (β).
Alpha is the size of the rejection region, while the
beta is the size of the acceptance region.
The most popular level of significance or alpha (α) are
the 0.01 and the 0.05 levels. If we want a smaller
probability of committing a Type I error, we can set
alpha (α) at values smaller than 0.01.
An α= 0.05, means that when a different set of samples was
taken from the same population, the probability of getting a
result which is the same as the one presently under study is
95% and the probability of getting a different result is 5%. A
5% significance level means that we can accept about 5
chances in 100 that we could reject the null hypothesis when it
should be accepted. Furthermore, a 5% significance level
implies that we are 95% confident that we have made the right
decision. The same argument follows for α= 0.01.
When Ho is rejected at α= 0.05, the result is said to be
significant. When it is rejected at α= 0.01, the result is said
to be highly significant.
Note: The level of significance is set at the beginning of the test
so that the researcher will not be tempted to change it when the
result does not conform to his desired outcome.
The Five (5) Steps Solution in Hypothesis Testing:
1. Formulate or state the null (H o) and alternative (H1) hypotheses.
2. Set the level of significance (α), then determine the type of
hypothesis test to use, and the tabular or p-value.
3. Set the criterion (when to reject H o). Determine and compute for
the test statistic.
4. Make your decision.
5. Formulate your conclusion.
The criterion in Step 3 is your guide in making a decision. It may be any of
the following statements:
A.Using Tabular Value of Z
1. One-tailed test (right directional)
 Reject Ho if the Z computed value is greater than or equal to the Z
tabular value.
2. One-tailed test (left directional)
 Reject Ho if the Z computed value is less than or equal to the Z
tabular value.
3. Two-tailed test (Z computed is positive)
 Reject Ho if the Z computed value is greater than or equal to the Z
tabular value.
4. Two-tailed test (Z computed value is negative)
 Reject Ho if the Z computed value is less than or equal to the Z
tabular value.
A special table called the Z-table is used to facilitate the work on
hypothesis testing. These values can be obtained using the table of the
areas under the normal curve.

Z-Table
α
Type 0.025 0.01 0.05

One-tailed ±1.96 ±2.33 ±1.65

Two-tailed ±2.33 ±2.58 ±1.96


B. Using the P-value
 Reject Ho if the probability value is less than or equal to the alpha
(α).
 A table of the p-values is found in any statistics books.

How to Choose the Appropriate Statistical test or Test


Statistic to be used?
A statistical test or test statistic is a calculated number that
is used to decide whether to reject or accept the null
hypothesis. The formula to be used for the test statistic
depends on the variable we are testing. The level of
measurement of the variable is the basis for choosing the
appropriate statistics to be used in testing the hypothesis.
The table given below summarizes the four levels of measurement and
the appropriate statistics for each level.

Appropriate Statistics for the Different Scales/Levels of Measurement


Scale/Level of Relations being defined Appropriate Statistical Examples of Statistics
Measurement test to be Used That Can be Used
Nominal Equivalence Nonparametric test Mode, frequency, Chi-
square test
Ordinal Equivalence, greater than, Nonparametric test Median, Spearman’s rank,
less than Friedman’s test, Kendall’s
tau percentile
Interval Equivalence, greater than, Nonparametric, Mean, Standard
less than, known ratio of parametric tests Deviation, Z-test, t-test,
any two intervals ANOVA, Pearson’s r
Ratio Equivalence, greater than, Nonparametric, Mean, Standard
less than, known ratio of parametric tests Deviation, Coefficient of
any two ratios variation, Pearson’s r,
Z-test, t-test, ANOVA
Common Statistical Tests
A.The Z-test (used when n is large, or n ≥ 30).
1. Z-test for comparing hypothesized and sample means
Hypothesized mean is the known mean or the perceived population mean.
2. Z-test for comparing 2 sample means
a. When the population standard deviation is given
b. When the sample standard deviation is given
Let us consider the following examples:
Example 1. The average score in the entrance examination in
mathematics at ABC High school is 80 with a standard
deviation of 10. A random sample of 40 students was taken
from this year’s examinees and it was found to have a mean
score of 84.

a.Is there a significant difference between the known mean


and the sample mean? Test at α= 0.05.

b.Does this mean that this year’s batch is better in


Mathematics than the previous batches?
Solution:
a. Since n=40, and only one sample mean is given, then we use
Z-test and the test statistic is:

= (84-80)
10
= 2.53
Five (5) Steps Solution
1. a) Ho: There is no significant difference between the hypothesized and
sample means (Ho: µ=80).

H1: There is a significant difference between the hypothesized and sample


means (H1: µ≠80)
2. α = 0.05; two-tailed test; Ztab is ±1.96
3. Criterion: Reject Ho if the Z- computed (Zc) is greater than or equal to 1.96
(Ztab or tabular value) or if Zc ≥ Ztab.
4. Decision: Reject Ho since Zc =2.53 is greater than the Ztab=1.96.
5. Conclusion: There is a significant difference between the hypothesized and
the sample means.
b. To answer the question, use the same computation and therefore
the same value for Zc=2.53. However, this time Ztab= 1.65.
Five (5) Steps Solution
1. Ho: This year’s batch is as good as the previous batches in
Mathematics (Ho: µ=80).
H1: This year’s batch is better in Mathematics than the previous
batches (H1: µ>80).
2. α =0.05; one-tailed test; Ztab is ± 1.65.
3. Criterion: Reject Ho if Z-computed value is greater than or equal to
1.65 or if Zc ≥ Ztab.
4.Decision: Reject Ho (Since the Z computed value is 2.53 which is
greater than the Ztab=1.65).
5.Conclusion: This year’s batch is better in Mathematics than the
Example 2: The principal of XYZ High School wants
to know which batch of students performed better in
English. He took a random sample of 40 students in
last year’s batch and found it to have a mean final
grade of 83 with a standard deviation of 7. Fifty (50)
students from this year’s batch were randomly taken
and it was found that they have a mean final grade
of 86 with a standard deviation of 10. Does this
indicate that the last year’s batch is poorer in
English than this year’s batch? Test at α= 0.01.
Five (5) Steps Solution

1. Ho: Last year’s batch is as good as this year’s


batch in English (Ho: µ1=µ2).

H1: Last year’s batch was poorer in English than


this year’s batch (H1: µ1 < µ2).

2. α = 0.01; one-tailed test; Z tabular is -2.33.

3. Criterion: Reject Ho if the Z-computed value is


less than or equal to -2.33 or if Z c ≤ Ztab.

4. Decision: Accept Ho (Since Zc > Ztab, that is -1.67


> -2.33).

5. Conclusion: Last year’s batch was as good as


this year’s batch in English.
Solve the following research problems. State the null and alternative
hypotheses then test it using the 5 steps solution.

1. A newsboy can sell an average of 45 newspaper a day. For the last


2 weeks (14 days), he sold an average of 38 newspapers with a
standard deviation of 14. Does this indicate that his sale has gone
lower? Test it at 0.01 level of significance.
2. Past record showed that the average final examination
grade in Math IV is 70 with a standard deviation of 8.0. A
random sample of 100 students was taken and found to
have a mean final exam grade of 71.8. Is this an indication
that the sample is better than the rest of the students?
Test it at 0.05 level of significance.
B. t-test (used if n < 30 and σ is unknown)
Note: If the sample size is small (n < 30), the values of the mean and
standard deviation fluctuate from sample to sample and the sampling
distribution of sample mean and standard deviation are no longer
standard normal distributions.

 t-distribution is like the Z-distribution. They are both symmetrical


about the mean. Both are bell-shaped, but the t-distribution is more
variable since t values depend on the fluctuation of the mean and
the standard deviation, whereas the Z values depend only on the
fluctuation of the mean from sample to sample. The two
distributions differ in standard deviation, Z has a standard deviation
of 1 while t has a standard deviation which is always greater 1.
What is a degree of freedom (df)?
Degree of freedom (df)
It is the number of variables which is free to vary.
It is the divisor, n-1 in the formula for variance and
standard deviation.
If the mean and standard deviation are computed from
samples of size n, the values of t are said to belong to a t-
distribution with df=n-1. Therefore, we have a different t-
curve for each possible sample size, such that the curve
becomes more and more like the standard normal curve as
n becomes larger or as n approaches infinity.
The figure given below shows the t-distribution with df = 3, 6, and ∞. The
curve for df =6 represents a sampling distribution of all t values computed from
repeated random samples of size n = 7 taken from a normal population.
Similarly, the curve for df = 3 represents the sampling distribution of all t values
computed from samples of size n = 4.
The steps in testing the significance of difference
between means using the t-test are just the same as
in the Z-test.

The difference lies in the use of the t-distribution with


n-1 degree of freedom instead of the normal
distribution.

The t-distribution is also known as the Student’s


distribution since it was developed by Gosset in
1908 under the name student.
t- distribution table
How to use the t distribution table to determine
significance?

1.Determine the degrees of freedom of your sample


provides (this is typically: n-1) and then locate the df
on the t-distribution table.
2. Find in the table: the alpha which you selected at the
start of the statistical analysis (an alpha of .05 and a
two-tailed test are typically used by researchers).
3. Find the intersecting point where the df and the
alpha cross. At the intersecting point you will find the t
value needed to reject the null hypothesis.
4. Compare the t value calculated from the data
to the t value identified on the t distribution table.
If the calculated t value is larger than the t value
found in the table, then the null hypothesis can
be rejected and the difference between the
group and the population can be considered
statistically significant (but not necessarily
“substantively” significant).
1. t-test for comparing hypothesized and sample means, and
population standard deviation (σ) is unknown
 This is used when only one sample mean is known.
2. t-test for comparing two independent sample means, and population
standard deviation (σ) is unknown.
 This is used when two sample means are known.
Independent samples are drawn from entirely different
populations.
3. t=test for dependent or correlated samples and s is unknown
Dependent samples are drawn from the same population or the
same set of samples subjected to different experimental
conditions.
Example 1. The average height of grade 10 students in a certain school
is 1.52 m. A random sample of 26 students were taken and were found to
have a mean height of 1.56m with a standard deviation of 0.11m. Are the
26 students in the sample significantly taller than the rest? Test at α=
0.05 level.
Five (5) Steps Solution
Solution:
1. Ho: The 26 students in the sample are as tall as the
other students (Ho: µ = 1.52).

H1: The 26 students in the sample are significantly taller


than the other students (H1: µ > 1.52).

2. α= 0.05; df = 26-1 = 25; ttab = 1.7081; one-tailed test


(right directional).

3. Criterion: Reject Ho if t-computed value is greater than


or equal to the t-tabular value, tc ≥ ttab.
4. Decision: Reject Ho (Since the tc > ttab, that is 1.85 > 1.7081.

5. Conclusion: The 26 students in the sample are significantly taller than the other
students.

Example 2. A teacher wanted to find out if the calculator-based method of teaching


Statistics is more effective than the lecture method. Two (2) classes of
approximately equal intelligences were selected. From one class, she considered
15 students with whom she used the calculator-based method of teaching, and
from the other class, she considered 14 students with whom she used the lecture
method. After several sessions, a test was given. The results are shown in the table
below.
Method n x s
Calculator- 15 28.6 6
based (1)
Lecture (2) 14 21.7 4.5
Solution: Five (5) Steps Solution
1. Ho: The calculator-based method of teaching
Statistics is as effective as the lecture method
(Ho: µ1 = µ2).

H1: The calculator-based method of teaching


Statistics is more effective than the lecture
method (H1: µ1 > µ2).

2. α=0.05; one-tailed, right directional; df=15+14-


2=27; ttab = 1.7033.

3. Criterion: Reject Ho if t-computed value is


greater than or equal to t tabular value that is
1.7033 or tc ≥ ttab.
4. Decision: Reject Ho (Since the tc = 3.50 > ttab =
1.7033).
5. Conclusion: The calculator-based method of
teaching Statistics is more effective than the
lecture method of teaching.
Example 3. The following are the weights in pounds of 15 students before and after
six (6) months of attending aerobics.
Weights 158 192 144 243 179 201 165 183 153 170 180 212 169 178 209
before
Weights 159 190 140 231 173 199 162 179 152 164 177 207 170 171 196
after

Solution:
First, we have to get the mean of the differences (d) and standard deviation of
the differences (Sd).

Weights 158 192 144 243 179 201 165 183 153 170 180 212 169 178 209
before
Weights 159 190 140 231 173 199 162 179 152 164 177 207 170 171 196
after
Differences -1 2 4 12 6 2 3 4 1 6 3 5 -1 7 13
Five (5) Steps Solution

1. Ho: Aerobics is not effective in reducing weights


(Ho: µ1 = µ2).

H1: Aerobics is effective in reducing weights


(Ho: µ1 > µ2).

2. α=0.05; one-tailed test (right directional); df = 15-1=14;


ttab = 1.7613

3. Criterion: Reject Ho if the t-computed value is greater


than or equal to the t-tabular value that is 1.7613 or
tc ≥ ttab.

4. Decision: Reject Ho (Since the tc=4.21 > ttab = 1.7613)

5. Conclusion: Aerobics is effective in reducing weights.


Solve the following research problems using the 5 steps solution in hypothesis testing then,
decide if the null hypothesis is rejected or accepted.
1. At the beginning of the school year, pre-test is given to all students in Algebra
to find out how much they know about the subject. Then, at the end of the
school year, post-test is administered to same students to find out how much
they have learned of the subject. A random sample of 20 students were taken
from the year’s batch and it was found out that they have the following test
scores.

Is there a significant difference between the pretest and posttest scores of


these students? Use α = 0.01.
2. The manufacturers of 2 different brands of light bulbs want to
know if there is a significant difference between the mean lifetimes
of their respective products. A random sample of 16 Pilit light bulbs
was tested and found out to have a mean life of 1250 hours with a
standard deviation of 250 hours. For a sample of 12 Hirit light
bulbs, the mean lifetime was 1400 hours with a standard deviation
of 300 hours. Use α = 0.01.
3. The following data represent the number of minutes that a student
stays inside the guidance counselor’s office on a certain day.
Is there a significant difference in the number of minutes that a
student stays inside the guidance counselor’s office on a certain
day? Test at α = 0.05.
THANK YOU

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy