Business Statistics: Module 6.
T-Test two sample test Page 1 of 9
Module 6. T-Test two sample test
T-Test two sample test – measures the difference between means of two
independent groups
T-test two sample test can be classified as:
Pooled variance t-test – assumes that the variances of the two independent
groups are equal.
Formula for pooled variance t-test is
T = (xbar1 – xbar2) .
S2p 1 + 1.
n1 n 2
t = test xbar1 = mean of group 1 xbar2 = mean of group 2
S2p = pooled variance n1 = sample of group 1 n2 = sample of group 2
Compute pooled variance first before solving t-test. Formula for S2p is
S2p = (n1 – 1)S21 + (n2 – 1)S22
(n1 – 1) + (n2 – 1)
S2p = pooled variance
S21 = variance of group 1 S22 = variance of group 2
n1 = sample of group 1 n2 = sample of group 2
Determine the degree of freedom; and together with the given level of
significance, locate the critical t-value from t-test distribution table at the end of
the references. Formula for degree of freedom is
df = n1 – 1 + n2 – 1
df = degree of freedom n1 = sample of group 1 n2 = sample of group 2
Separate variance t-test – assumes that the variances of the two independent
groups are unequal
Formula for separate variance t-test is
T = (xbar1 – xbar2) .
S21 + S22 .
n1 n2
Business Statistics: Module 6. T-Test two sample test Page 2 of 9
t = test xbar1 = mean of group 1 xbar2 = mean of group 2
2
S 1 = variance of group 1 S22 = variance of group 2
n1 = sample of group 1 n2 = sample of group 2
Note that in separate variance t-test, there is no need to compute for the pooled
variance to calculate t-test.
However, the computation for the degree of freedom (v) for separate variance t-
test is different from the pooled variance t-test. Its formula is
df = v = S21 2 + S22 2
n1 n2 .
S12 2 S22 2
n1 + n2_
(n1-1) (n2-1)
Problems illustration
1. Mr. Honesto, human resource manager of YOLO company, received a complaint
from the employees’ union officer about the alleged unequal annual salaries given to
male and workers. Naturally, he denied such complaint; and claimed that the firm is
fair and just in terms of employees’ compensations regardless of the staff’s gender.
To support his claim, he conducted a survey about the annual salaries of randomly
select 100 employees; and the summary statistics of the results is shown on the
table below. Assuming unequal variance and at a .05 level of significance, is there
significant difference on the average annual salaries of the male and female
employees?
Gender Male Female
Sample size (n) 47 53
Average annual salary (in Php10,000) (xbar) 35 34.75
Variance (S2) 123 61
The focus of the problem is the alleged unequal annual salaries which male and
female employees received from Z company. Mr. Honesto wanted to prove that the
Union’s complaint is not true by conducted a survey among randomly select 100
employees.
As previously mentioned, your guide in writing your hypothesis is the given question
in the problem, which is your alternative hypothesis; and you need to state it in
declarative form. Based on the question, we need to state a two-tail hypothesis
because there is no given direction on it.
Also, please note that no value should appear in the null and alternative hypothesis.
Business Statistics: Module 6. T-Test two sample test Page 3 of 9
Null hypothesis: There is no significant difference on the average annual salaries of
male and female employees.
Alternative hypothesis: There is significant difference on the average annual
salaries of male and female employees.
Since it’s a two-tail hypothesis, we need to divide the given alpha or level of
significance by 2.
Level of significance: .05/2 = .025
Before you can determine the t-test critical value, you need to know the degree of
freedom. Since its stated in the problem to assume unequal variance, we need to
use the degree of freedom formula for separate variance t-test.
df = v = S21 + S22 2 = 123 + 61 2 = 81.42 or 81
n1 n2 . 47 53
S12 2 S22 2 123 2 61 2
n1 + n2_ 47 + 53_
(n2-1) (n2-1) (47-1) (53-1)
Please note that you need to round down to whole number the computed degree of
freedom. 81.42 round down to 81
Next, determine the t-test critical @ .025 level of significance (column headings) and
degree of freedom of 81 (row headings) from the t-test distribution table after the
references section. The value where the two factors intercept will the critical value.
t-test critical = +1.990 two tail hypothesis, positive-negative critical value
Draw the normal curve and plot the critical t-values on the curve. Since it’s twotail
hypothesis, shade the two tails of the curve.
Normal curve
-1.990 1.990
Write your decision rule.
Decision rule: Reject null hypothesis if T > +1.990 or t < -1.990; otherwise, do not
reject the null hypothesis
Calculate the t-test value
T = (xbar1 – xbar2) = (35 – 34.75) = 0.129 round off to three decimal places
S21 + S22 . 123 + 61 since the t-critical value has
n1 n2 47 53 three decimal places
Business Statistics: Module 6. T-Test two sample test Page 4 of 9
Next, state your conclusions; and give your recommendations.
Conclusion: Do not reject the null hypothesis, 0.129 < 1.990; which means there is
no enough evidence to support that there is difference on the annual salaries of
male and female employees of YOLO company.
Recommendation: Mr. Honesto has proven its claim that YOLO is fair and just in
paying employees’ salaries ’s fairness based on their positions and competencies
and gender was never a factor when it comes to compensation. Thus, Mr. Honesto
needs to consistently makes sure that the firm’s HR policies maintain its objectivity
particularly on compensations and benefits as well as on promotion so as
employees particularly females will not complain of discrimination. (You can give
more recommendations aside from the given example.)
2. Mr. Led, owner of a manufacturing firm of energy saving light bulbs would want to
improve the life expectancy (in terms of hours) of its produced bulbs. To achieve
such, he needs to upgrade the machine its uses in producing light bulbs. Sales
representatives of two different types of machine approached and offered their
machines to Mr. Led. In order to determine which machine can help improve the life
expectancy of the light bulbs, Mr. Led conducted separate experiments on the two
machines, the results of which are shown on the table below. Assuming equal
variance and at a .05 level of significance, is there significance difference on the
average life expectancy of light bulbs produced by machine I and machine II?
Type of Machine Sample (n) Mean life expectancy (xbar) Variance
Machine I 35 395 100
Machine II 35 382 93
Null hypothesis: There is no significant difference on the average life expectancy of
the light bulbs produced by machine I and machine II.
Alternative hypothesis: There is significant difference on the average life expectancy
of the light bulbs produced by machine I and machine II.
Level of significance: .01/2 = .005 divide alpha by 2 since its two-tail hypothesis,
Since it states “assume equal variance”, we will use the degree of freedom formula
for pooled variance test
Degree of freedom = n1 + n2 – 2 = 35 + 35 – 2 = 68
Critical value: +2.650 two-tail hypothesis, positive-negative critical value (+2.650)
Normal curve
Business Statistics: Module 6. T-Test two sample test Page 5 of 9
-2.650 2.650
Decision rule: Reject the null hypothesis if t < -2.650 or t > 2.650; otherwise, do
not reject the null hypothesis.
Computation:
Since it’s a pooled variance t-test, we need to determine the pooled variance first
prior to computing t-test.
Pooled variance (S2p) = (n1 – 1)S21 + (n2 – 1)S22 = (35-1)(100) + (35-1)(93) = 96.5
(n1 – 1) + (n2 – 1) (35-1) +(35-1)
We are now ready to calculate the t-test since we have the pooled variance value.
T = (xbar1 – xbar2) = (395 – 382) = 5.536
S2p 1 + 1 . 96.5 1 + 1_
n1 n2 35 35
Conclusion: reject the null hypothesis, 5.536 > 2.650; which means there is
significant difference on the average life expectancy of light bulbs produced by
machine I and machine II.
Recommendation: Based on the results light bulbs produced using Machine I have
longer life expectancy that those produced by Machine II. Hence, Mr. Led should
purchase Machine I since it can contribute a lot in achieving its goal of improving the
life expectancy of its energy saving light bulbs. (You can give more
recommendations aside from the given example.)
End of Module Exercises
Read and analyze the problems carefully. Work on the problem and follow the
step by step procedure in solving it – from the null hypothesis to the
recommendation.
1. A researcher would like to determine if a low-carb diet is more effective in losing
weights (in kilograms) than a low-fat diet. To test his idea, he approached and
requested randomly select 100 obese patients to participate in his study about diet
programs to which they agreed. He equally distributed these patients to the two diet
programs – that is, he put 50 patients on the low-carb diet program and 50 on the
low-fat diet program. For three months these patients obediently follow their
respective diet programs. At the end of the three-month experiment, he collected
the necessary data, the summary of which are shown on the table next page.
Assuming equal variance and at a .01 level of significance, is there evidence that
liquid diet program is more effective in losing weights than powder diet program?
Business Statistics: Module 6. T-Test two sample test Page 6 of 9
Type of diet program Sample size Mean weight loss (in kg) Variance
Low-carb diet 50 17.22 3.45
Low-fat diet 50 15.91 3.18
2. There are two types of fertilizers are out in the market – artificial fertilizers (Type A)
and organic fertilizers (Type B). Although many farmers commonly use artificial
fertilizers in their cornfield, some farmers use organic fertilizers because they believe
it can increase their harvest. Thus, a group of farmers conducted a research about
the corn produced (in pounds) of 30 farmers who use the two types of fertilizers. The
gathered data are shown below. Assuming an unequal variance and at a .05 level of
significance, is there evidence of significance difference on the corn yields of the two
types of fertilizers?
Note: Compute the mean and variance for each type of fertilizers first before you
proceed with analyzing the whole problem.
A 587 870 566 491 388 735 579 690 713 469 348 615 415 508 491
B 646 874 565 503 410 723 665 685 729 456 400 630 436 539 519
3. Credit card companies are concerned that their clients use credit cards less
frequently to minimize their credit debts based on the reported 2018 credit debts. In
2019, another survey was conducted among credit card holder to determine their
credit spending and compare it with 2018 report. The comparative summary
statistics (in Php1,000) for 2018 and 2019 are shown on the table below. Assuming
equal variance and at a .05 level of significance, is there evidence that the average
credit debts is lower in 2019 than in 2018?
Year Sample size Average credit debts variance
2019 500 56.50 11.96
2018 500 57.95 12.04
4. The research director of a leading beverage conducted a research to measure the
effectiveness of a new flavoring of its beverage compared to beverage with classical
flavoring. A sample of 20 persons tasted the beverage with the classical flavoring,
and 30 persons tasted the one with new flavoring. The participants were asked to
rate their enjoyment on the beverage, the highest score is 20 and the lowest is 0.
The summary result of the study is shown below. Assuming equal variance and at a
.01 level of significance, is there significant difference between the enjoyment level
of the two differently flavored beverages?
Flavoring Sample Average enjoyment Variance
New 30 16.75 8.97
Classical 20 15.95 8.75
5. Two medical researchers looked into the effectiveness of a treatment for
hypertension or high blood pressure. In a clinical trial, 45 patients with hypertensions
Business Statistics: Module 6. T-Test two sample test Page 7 of 9
were randomly assigned to either Group A (placebo control or Group B (treatment);
and were closely monitored for three months. After which, the researchers
measured and recorded the changes in the blood pressure of the patients in each
group. The summary of the results is shown below. Assuming equal variance and
at .01 level of significance, is there evidence of significant difference on the change
in blood pressures of the two groups of patients?
Groups Sample Average change in blood pressure variance
A (placebo control) 21 -0.218 16.81
B (treatment) 24 3.359 21.19
References
Albright, S. et al. (2015). Business analytics: data analysis and decision making (5th
ed). Cengage Learning.
Anderson, D., Sweeney, D.J., [Link]., (2018). Modern business statistics. Australia:
Cengage Learning.
Antivola, H. (2015). Business statistics: a modular approach. Books Atbp. Publishing.
Anywhere Math. (2016). Introduction to Statistics.
[Link]
Berenson, M.L., Levine, D.M., & Krehbiel, T.C. (2015). Basic business statistics:
concepts and applications. Pearson Education Sou7th Asia Pte. Ltd.
Bowerman, B. (2017). Business statistics in practice: using modeling, data, and
analytics (8th ed.). McGraw-Hill Education.
Jaggia, S. (2019). Business statistics: communicating with numbers (3rd ed.). McGraw-
Hill Education.
Lee, N. (2016). Business statistics: using excel & SPSS. Sage.
Simple Learning Pro. (2015). Mean, median, mode, range, and standard deviation.
[Link]
Sharpe, N. (2015). Business statistics 3rd ed. Pearson Education.
Willoughby, D. (2015). An essential guide to business statistics. John Wiley & Sons.
Business Statistics: Module 6. T-Test two sample test Page 8 of 9
Business Statistics: Module 6. T-Test two sample test Page 9 of 9