Hypothesis Testing Examples For Statistical Analysis

Scenario one: Do University of Manitoba students enrolled in Distance Education have different GPAs than students enrolled in regular programs?

The populations being compared here are people living in Winnipeg and the people living in the rest of Canada.

Save Time On Research and Writing
Hire a Pro to Write You a 100% Plagiarism-Free Paper.
Get My Paper

Hypothesis test

H0: (Null hypothesis): People living in Winnipeg make the same amount of money people living in the rest of Canada make.

H1: (Alternative hypothesis): People living in Winnipeg make more money than people living in the rest of Canada.

The appropriate hypothesis for this test would be a one–tailed test since the alternative hypothesis has given a one direction outcome. That is, people living in Winnipeg can only be making MORE money THAN people living in the rest of Canada.

Save Time On Research and Writing
Hire a Pro to Write You a 100% Plagiarism-Free Paper.
Get My Paper

The populations being compared here are University of Manitoba students enrolled in regular programs and those enrolled in distance education.

Hypothesis test

H0: (Null hypothesis): Students of University of Manitoba enrolled in Distance Education and regular programs have equal GPAs.

H1: (Alternative hypothesis): Students of University of Manitoba enrolled in Distance Education and regular programs have different GPAs.

The appropriate hypothesis for this test would be a two–tailed test since the alternative hypothesis has given a two-sided impression possibility. That is, the students enrolled in distance education could be having higher or lower GPAs than the regular students hence a two-tailed test is used.

Scenario three: Do males laugh more than females?

The populations being compared here are males and females..

H0: (Null hypothesis): Male and females laugh equally.

H1: (Alternative hypothesis): Males laugh more than females.

The appropriate hypothesis for this test would be a one–tailed test since the hypothesis has given a direction to the outcome, that is, male laugh more than females.

Question two

Study A

  1. Critical value = 5%
  1. Critical value = 0.5% on both sides
  • Critical value = 5% on both sides

 Student Participant

1

2

3

4

5

6

7

8

9

10

Skateboarder Coolness

5

5

7

7

7

3

5

8

9

10

Table 1

Step 1

Population 1: High school students who skateboard to school

Population 2: High school students who do not skateboard to school

Hypothesis test

H0: (Null hypothesis): Students who skateboard to school and those who do not skateboard have the same coolness.

H1: (Alternative hypothesis): Students who skateboard to school are cooler than the rest.

Step 2

Calculating the standard error;

Step 3

The study sets the level of significance to be 5%. Since this is a directional hypothesis, only the positive side of the normal curve will be used. For 5% level of significance, the value of Zscore will be 1.64 as read from the normal tables.

Step 4

Determining the sample score of the study we have;

Step 5

Decision rule

The least Z score cut off to reject the null hypothesis was 1.64. The survey’s calculated Z score is 5. This value is greater than the cut-off value of 1.64. The decision therefore is that the alternative hypothesis is statistically significant at 0.05 level of significance.

Scenario two: Does body size affect walking pace?

Question 1

One sample t-test

A research was conducted to establish whether the mean body mass index (BMI) in kg/m3 was 25 among 30 patients who had signs of high blood pressure in a hospital.

The research employed a one-sample t-test since there was only one sample being tested against a mean of 25.

Hypothesis test

H0: (Null hypothesis): Mean body mass index among the patients is 25 kg/m3.

H1: (Alternative hypothesis): Mean body mass index among the patients is not 25 kg/m3.

Data

BMI in Kg/m3

27.4

25.6

15.9

20.9

28.5

20.9

21

34.2

20

20.8

23.7

25.8

18.1

26.1

30

29.2

24.8

18.1

25.4

21.5

27

28.3

29.3

21

22.4

24.3

15.1

28.3

25.4

27.9

Table 2

Since the sample was 30, the central limit theorem was applied and an assumption of normality arrived at.

One-Sample Test

Test Value = 25

t

df

Sig. (2-tailed)

Mean Difference

95% Confidence Interval of the Difference

Lower

Upper

BMI

-.936

29

.357

-.77000

-2.4517

.9117

Table 3

The survey’s calculated p-value score is .36. This value is greater than the level of significance which is 0.05. The decision therefore is to accept the null hypothesis and reject the alternative hypothesis. The conclusion is that the null hypothesis is statistically significant at 0.05 level of significance.

Question 2

T-test for repeated measures (paired sample t-test)

A research is conducted to test whether heart beat rates are different before having a walk of 300 metres and after.

The appropriate test for the research is a paired sample t-test since we are comparing two variables. That is heart beat rate before and after 300 meters of walk. Since the sample was more than 30, the central limit theorem was applied and an assumption of normality arrived at.

Hypothesis test

H0: (Null hypothesis): There is no significant difference in heart rate before and after walking for 300 metres.

H1: (Alternative hypothesis): There is a significant difference in heart rate before and after walking for 300 metres.

Data (first 10)

Heart Rate at rest (bpm)

Heart Rate Post 300m Walk (bpm)

67

83

81

97

87

105

70

90

73

98

70

104

87

98

80

106

73

107

61

85

Table 4

Results table

Paired Samples Test

Paired Differences

t

df

Sig. (2-tailed)

Mean

Std. Deviation

Std. Error Mean

95% Confidence Interval of the Difference

Lower

Upper

Pair 1

heart beat rate at rest – heart beat rate after walking 400 meters

-23.22500

12.85119

2.03195

-27.33501

-19.11499

-11.430

39

.000

Table 5

The survey’s calculated p-value score is .00. This value is less than the level of significance which is 0.05. The decision therefore is to reject the null hypothesis and accept the alternative hypothesis. The conclusion is that the alternative hypothesis is statistically significant at 0.05 level of significance.

Question 3

A sample of 46 intern accountants employed in a bank had been trained differently. The first 23 had gone through PC- based training while the other 23 went through traditional lectures. The human resources department wanted to establish whether there is a significant difference in their mean aptitude scores.

The appropriate test was an independent samples t-test since the two samples are independent. They have been drawn from different populations.

Since the sample was drawn from a normally distributed population an assumption of normality was arrived at.

Scenario three: Do males laugh more than females?

Hypothesis test

H0: (Null hypothesis): There is no difference in mean aptitude test scores between the two groups.

H1: (Alternative hypothesis): There is a significant difference in mean aptitude test scores between the two groups.

Independent Samples Test

Levene’s Test for Equality of Variances

t-test for Equality of Means

F

Sig.

t

df

Sig. (2-tailed)

Mean Difference

Std. Error Difference

95% Confidence Interval of the Difference

Lower

Upper

PC_training

Equal variances assumed

11.158

.002

-2.570

44

.014

-10.23478

3.98200

-18.25997

-2.20960

Equal variances not assumed

-2.570

24.771

.017

-10.23478

3.98200

-18.43970

-2.02987

Traditional_lectures

Equal variances assumed

12.152

.001

-1.057

44

.296

-4.40826

4.17203

-12.81643

3.99991

Equal variances not assumed

-1.057

25.322

.301

-4.40826

4.17203

-12.99517

4.17865

Table 6

Compare the p-value under Lavene’s test for equality of variances with the level of significance (0.05). As can be observed, the p-value calculated (0.002) is less than the level of significance (0.05). The decision is therefore to reject the null hypothesis. The conclusion is that the alternative hypothesis is statistically significant at 0.05 level of significance.

Question 1

The appropriate test was an analysis of variance since the variables were more than two.

Dependent variable: Walking time

Independent variables: Body size

Overweight

Heavyweight

Obese

normal

298.4

343.37

289.21

288.4

305.97

363.72

290.53

295.97

345.31

299.41

308.4

335.31

359.47

276.85

294.22

266.85

260.63

368.37

350.44

358.37

288.9

337.46

319.5

327.46

347.55

377.72

244.19

357.72

330.91

311.94

285.09

310.91

416.5

277.38

248.31

386.5

321.76

247.8

299.28

301.76

Table 7

Statistics

overweight

heavyweight

obese

normal

N

Valid

10

10

10

10

Missing

36

36

36

36

Skewness

.607

-.249

.037

.266

Std. Error of Skewness

.687

.687

.687

.687

Kurtosis

1.005

-1.276

.543

-.686

Std. Error of Kurtosis

1.334

1.334

1.334

1.334

Table 8

As can be observed above, the kurtosis values are near zero indicating normality.

H0: (Null hypothesis): All the mean times in all the four groups are equal.

H1: (Alternative hypothesis): At least one mean is different

Table of results

ANOVA

Sum of Squares

df

Mean Square

F

Sig.

overweight

Between Groups

16978.747

9

1886.527

.

.

Within Groups

.000

0

.

Total

16978.747

9

heavyweight

Between Groups

17812.225

9

1979.136

.

.

Within Groups

.000

0

.

Total

17812.225

9

obese

Between Groups

8742.267

9

971.363

.

.

Within Groups

.000

0

.

Total

8742.267

9

Table 8

As can be observed, the p-value calculated (0.00) is less than the level of significance (0.05). The decision is therefore to reject the null hypothesis. The conclusion is that the alternative hypothesis is statistically significant at 0.05 level of significance.

Question 2

Factorial anova

A study is conducted to establish the effect of gender (male and female) and body size (obese and normal) on time used to walk 200 meters. It is hypothesized that gender and body size affect the speed at which people walk. So the research question is, does gender or body size affect speed of walking?

Dependent variable: Walking time

Independent variables: Gender and body size

Factorial anova was appropriate since the study focused on establishing whether there is a difference between mean time taken to walk 200 meters between the obese and normal individuals.

Hypothesis test 1

H0: (Null hypothesis): The average amount of time taken to walk between the normal and obese groups is the same.

H1: (Alternative hypothesis): The average amount of time taken to walk between the normal and obese groups is not the same.

Hypothesis test 2

H0: (Null hypothesis): The average amount of time taken to walk between the males and females is the same.

H1: (Alternative hypothesis): The average amount of time taken to walk between the males and females is not the same.

Descriptive Statistics

Dependent Variable:   time_in_minutes  

gender

body_size

Mean

Std. Deviation

N

male

obese

327.5400

43.43417

10

normal

320.4020

44.48748

10

Total

323.9710

42.94778

20

female

obese

292.2100

32.97211

9

normal

320.7755

35.84174

11

Total

307.9210

36.69412

20

Total

obese

310.8047

41.89179

19

normal

320.5976

39.15307

21

Total

315.9460

40.25702

40

Table 9

Tests of Between-Subjects Effects

Dependent Variable:   time in minutes  

Source

Type III Sum of Squares

df

Mean Square

F

Sig.

Corrected Model

6869.907a

3

2289.969

1.463

.241

Intercept

3954871.018

1

3954871.018

2527.318

.000

gender

3039.549

1

3039.549

1.942

.172

body_size

1142.071

1

1142.071

.730

.399

gender * body_size

3170.827

1

3170.827

2.026

.163

Error

56334.558

36

1564.849

Total

4056079.462

40

Corrected Total

63204.465

39

a. R Squared = .109 (Adjusted R Squared = .034)

Table 10

The factorial ANOVA shows that there was no main effect of body size on time taken (.24, p > .05). There was also no main effect of gender on time taken (.17, p > .05).

Question one: One sample t-test

There was also a significant interaction between the two factors (gender and body size) (.16, p > .05).

Plot of means of interaction effects

Interpretation

  • The main effect of time: Normal people do not have difference in walk time regardless of gender. 

PART FOUR

NON-PARAMETRIC TESTS

Question 1

Chi-square test for goodness of fit

A research was conducted on 30 individuals after 3 companies advertised their brands of new washing powders. The 30 individuals were asked which washing powder they would prefer. It is assumed that before the campaign preference for the washing powders was the same across the three. The research question therefore is, did the advertising campaign have an effect on the consumers’ preference on the washing powders?

Chi-square test for goodness of fit was appropriate in this research since it was comparing effect of a factor on proportions before and after.

The washing powders were A, B and C. They were chosen as in the table below;

Powder A

Powder B

Powder C

9

16

5

Table 11

Hypothesis test 1

H0: (Null hypothesis): There was no effect on consumer preference of the three washing powders after the campaigns

H1: (Alternative hypothesis): There was a significant effect on consumer preference of the three washing powders after the campaigns.

powder_type

Observed N

Expected N

Residual

Powder A

9

10.0

-1.0

Powder B

15

10.0

5.0

Powder C

6

10.0

-4.0

Total

30

Table 12

Test Statistics

powder_type

Chi-Square

4.200a

df

2

Asymp. Sig.

.122

a. 0 cells (0.0%) have expected frequencies less than 5. The minimum expected cell frequency is 10.0.

Table 13

As can be observed from the results table, the p-value (1.22) is greater than significance level (0.05). Therefore there is sufficient evidence to reject the null hypothesis. The conclusion is that the campaigns had a significant effect on consumers’ preference of the three washing powders.

Question 2

Chi-square test for independence

For a research to predict the demand for analysis package courses in a college, it was presumed or hypothesized that students’ undergraduate degree courses affected their choice of analysis packages. That is some degree courses would tend to have a preference for certain analysis packages. Therefore, are the two variables independent?

The chi-square test for independence is appropriate in this question since it involved two qualitative variables (the analysis software and degree courses).

The variables are degree course and analysis software.

The below contingency table gives a summary of the data;

Analysis software

Degree course

SPSS

R-PROG

Total

Bsc. Mathematics

8

6

14

Bsc. Statistics

9

7

16

Total

17

13

30

Table 14

Hypothesis test

H0: (Null hypothesis): The two variables (degree course and analysis software) are independent

H1: (Alternative hypothesis): The two variables (degree course and analysis software) are dependent

Results table

Chi-Square Tests

Value

df

Asymp. Sig. (2-sided)

Exact Sig. (2-sided)

Exact Sig. (1-sided)

Pearson Chi-Square

.002a

1

.961

Continuity Correctionb

.000

1

1.000

Likelihood Ratio

.002

1

.961

Fisher’s Exact Test

1.000

.626

Linear-by-Linear Association

.002

1

.961

N of Valid Cases

30

a. 0 cells (0.0%) have expected count less than 5. The minimum expected count is 6.07.

b. Computed only for a 2×2 table

Table 15

As can be observed from the results table, the p-value (.63) is greater than significance level (0.05). Therefore there is sufficient evidence to reject the alternative hypothesis. The conclusion is that the two variables are independent.

Question 3

For a research to assess the effectiveness of advertising, two products were compared (product X and product Y). The products were advertised after which 30 participants allowed to rate their chances of purchasing the products. The rating was between 1 and 5 with 5 indicating “will definitely buy”. 15 participants rated X and the other rated Y.

This test was appropriate since the variables involved ordinal scale and they were also not normally distributed.

Dependent variable: Likelihood of purchasing

Independent variables: advertising

Hypothesis test

H0: (Null hypothesis): Advertising did not have an effect on the likelihood of purchase.

H1: (Alternative hypothesis): Advertising had a significant effect have an effect on the likelihood of purchase.

Table of results

Ranks

PRODUCT

N

Mean Rank

Sum of Ranks

LIKELIHOOD

X

15

15.17

227.50

Y

15

15.83

237.50

Total

30

Table 16

Test Statisticsa

LIKELIHOOD

Mann-Whitney U

107.500

Wilcoxon W

227.500

Z

-.213

Asymp. Sig. (2-tailed)

.831

Exact Sig. [2*(1-tailed Sig.)]

.838b

a. Grouping Variable: PRODUCT

b. Not corrected for ties.

Table 17

As can be observed from the results table, the p-value (.83) is greater than significance level (0.05). Therefore there is sufficient evidence to reject the alternative hypothesis. The conclusion is that the two variables are independent.