You are on page 1of 18

2/10/2020

Business Research Method

Prof. Ravi Shekhar Kumar

XLRI- Xavier School of Management, Jamshedpur


ravishekhar@xlri.ac.in

Session-8

Two Independent Sample Test

1
2/10/2020

Problem: Two Independent Sample Test


• To test Whether the mean of familiarity with internet for
male & female is different or same,

• We can use two independent sample t-test or Z-test,


depending on situation.

• Result will show whether familiarity with internet is same or


different for male & female.

Two Independent Sample Test: Variance Test


• In the case of means for two independent samples, the
hypotheses take the following form.

2
2/10/2020

Two Independent Sample Test


• An F test of sample variance may be performed if it is not
known whether the two populations have equal variance. In
this case, hypotheses are:

H0: 2 = 2
1 2

H1: 2 2
1 2

Two Independent Sample Test

Group Statistics

Std. Error
Sex N Mean Std. Deviation
Mean

Male 14 5.71 1.267 .339


Familiarity
Female 15 3.80 1.265 .327

Independent Samples Test


Levene's Test for
t-test for Equality of Means
Equality of Variances
95% Confidence
Sig. (2- Mean Std. Error Interval of the
F Sig. t df Difference
tailed) Difference Difference
Lower Upper
Equal
variances .015 .902 4.070 27 .000 1.914 .470 .949 2.879
assumed
Familiarity
Equal
variances 4.070 26.857 .000 1.914 .470 .949 2.880
not assumed

3
2/10/2020

Paired Sample Test

Problem: Paired Sample Test


• To test whether the mean of attitude towards internet &
attitude towards technology is same or not.

• We can use paired sample t-test.

• Result will show whether attitude towards internet & attitude


towards technology is same or different for the sample.

4
2/10/2020

Paired Sample Test


• Difference in these cases is examined by a paired samples t-test.
• To compute t for paired samples, paired difference variable, denoted by
D, is formed and its mean & variance calculated. Then t statistic is
computed.
• Degrees of freedom are n - 1, where n is number of pairs.

Paired Sample Test

Number Standard Standard


Variable of Cases Mean Deviation Error

Internet Attitude 30 5.167 1.234 0.225


Technology Attitude 30 4.100 1.398 0.255

Difference = Internet - Technology

Difference Standard Standard 2-tail t Degrees of 2-tail


Mean deviation error Correlation prob. value freedom probability

1.067 0.828 0.1511 0.809 0.000 7.059 29 0.000

10

10

5
2/10/2020

Hypothesis Testing for Examining Differences

Hypothesis Tests

Parametric Tests Non-parametric Tests


(Metric Tests) (Nonmetric Tests)

One Sample Two or More One Sample Two or More


Samples Samples
* t test * Chi-Square
* Z test * K-S
* Runs
* Binomial
Independent Paired
Samples Independent Paired
Samples
Samples Samples
* Two-Group t * Paired
test * Chi-Square * Sign
t test * Mann-Whitney * Wilcoxon
* Z test

11

11

Non-Parametric Test

12

6
2/10/2020

Non-Parametric Tests
• Nonparametric tests are used when the independent
variables are nonmetric.

• Like parametric tests, nonparametric tests are available for


testing variables from one sample, two independent
samples, or two related samples.

13

13

Non-Parametric Test: One Sample test

14

7
2/10/2020

Non-Parametric Test: One Sample


• Sometimes researcher wants to test whether observations
for a particular variable could reasonably have come from a
particular distribution.
– Kolmogorov-Smirnov (K-S)
– Chi-square test
– Binomial test
– Runs test

15

15

One Sample: Non-Parametric Test


• Kolmogorov-Smirnov (K-S) one-sample test is one such
goodness-of-fit test.
• Chi-square test can be performed on a single variable
from one sample. In this context, chi-square serves as a
goodness-of-fit test.
• Binomial test is also a goodness-of-fit test for dichotomous
variables.
• Runs test is a test of randomness for dichotomous
variables. (To determine whether the order or sequence in which
observations are obtained is random)

16

16

8
2/10/2020

K-S One-Sample Test


• To test whether one variable comes from a particular
distribution (Theoretical distribution vs Observed distribution)

• Hypothesis
Ho: Internet Usage are normally distributed
H1: Internet Usage are NOT normally distributed

17

17

K-S One-Sample Test

Descriptive Statistics
Std.
N Mean Minimum Maximum
Deviation
Internet Usage
30 6.60 4.296 2 15
Hrs/Week

One-Sample Kolmogorov-Smirnov Test


Internet Usage
Hrs/Week
N 30
a,b Mean 6.60
Normal Parameters
Std. Deviation 4.296
Absolute .222
Most Extreme
Positive .222
Differences
Negative -.142
Test Statistic .222
Asymp. Sig. (2-tailed) .001c
a. Test distribution is Normal.
b. Calculated from data.
c. Lilliefors Significance Correction. 18

18

9
2/10/2020

K-S One-Sample Test

19

19

K-S Table

20

20

10
2/10/2020

Lilliefors
Test Table

21

21

One-Sample Chi-Square goodness of fit Test


• Chi – Square goodness-of-fit test is a statistical procedure
used to determine…
• …whether observed frequencies at each level of one
categorical variable are similar to or different from the
frequencies we expected at each level of the categorical
variable.

22

22

11
2/10/2020

One-Sample Chi-Square goodness of fit Test


• Observed frequency vs Estimated frequency

χ2 = (fo - fe)2
Σ fe
• Uniform distribution
Ho: The ratings of familiarity with internet are uniformly distributed
H1: The ratings of familiarity with internet are not uniformly
distributed.

• Expected Distribution
Ho: The observed distribution is the same as the expected distribution
H1: The observed distribution is not the same as the expected
distribution
23

23

Exercise: One-Sample Chi-Square Test


Familiarity measured on 1-7 scale ((only six categories, as one category
count is 0)
1. To test whether rating is uniformly distributed
2. To test whether rating follows below mentioned expected distribution;
Expected Distribution of familiarity (only six categories, as one
category count is 0):
– 10%,
– 20%,
– 20%,
– 10%,
– 25%,
– 15%
– If sum of % all categories do not become 100 then rescaling of % is
done to make it 100%.

24

24

12
2/10/2020

Binomial Test
• Expected Proportion (for testing Population proportion)

Ho: p = 0.5

H1: p =/ 0.5

25

25

One-Sample Runs Test


• A "run" of a sequence is a maximal non-empty segment of
sequence consisting of adjacent equal elements.
– Ex: 22-element-long sequence "++++−−−+++−−++++++−−−−"
consists of 6 runs, 3 of which consist of "+" & others of "−".

• Run test is based on null hypothesis that each element in


sequence is independently drawn from same distribution.
• Test of Randomness
Ho: The observations in the sample are generated randomly
H1: The observations in the sample are NOT generated randomly.

26

26

13
2/10/2020

Non-parametric Test: Two Independent Sample test

Chi-Square Test for independence

27

Two Independent Sample: Nonparametric Test


Gender
Row
Internet Usage Male Female Total
Light (1) 5 10 15
Heavy (2) 10 5 15

Column Total 15 15

Number of males & females who use Internet for shopping.

• Exercise:
Is the proportion of respondents using the Internet for
shopping indifferent to gender (males and females)?

28

28

14
2/10/2020

Two Independent Sample: Nonparametric Test


• Chi-Square Test for independence: …is a statistical
procedure to determine whether frequencies observed at
the combination of levels of two categorical variables are
similar to frequencies expected.

• Null hypothesis (H0) of NO association between two


variables will be rejected only when calculated value of
test statistic is greater than critical value of chi-square
distribution with appropriate degrees of freedom.
– An important characteristic of chi-square statistic is df associated
with it. df = (r - 1) x (c -1).

29

29

Two Independent Sample: Nonparametric Test

(f - f )2
χ2 =
Σ
o e

f
e

n rn c
fe = n

where nr = total number in the row


nc = total number in the column
n = total sample size

30

30

15
2/10/2020

Two Independent Sample: Nonparametric Test


Chi-Square Tests

Asymp. Sig. Exact Sig. Exact Sig.


Value df (2-sided) (2-sided) (1-sided)
Pearson Chi-Square
3.333a 1 .068
Continuity
Correctionb 2.133 1 .144
Likelihood Ratio
3.398 1 .065
Fisher's Exact Test
.143 .072
Linear-by-Linear
Association 3.222 1 .073
N of Valid Cases
30
a. 0 cells (0.0%) have expected count less than 5. The minimum expected
count is 7.50.
b. Computed only for a 2x2 table

31

31

Strength of Association in Cross-Tabulation


• phi coefficient is used as a measure of strength of
association in special case of a table with two rows & two
columns (a 2 x 2 table).

χ2
φ=
n

32

32

16
2/10/2020

Strength of Association in Cross-Tabulation


• While phi coefficient is specific to a 2 x 2 table,
contingency coefficient (C) can be used to assess strength
of association in a table of any size. Can be applicable to
square table.
χ2
C=
χ2 + n

• Contingency coefficient varies between 0 & 1.


• Maximum value of contingency coefficient depends on size
of table (number of rows & number of columns). For this
reason, it should be used only to compare tables of same
size.
33

33

Strength of Association in Cross-Tabulation


• Cramer's V is a modified version of phi correlation
coefficient & is used in tables larger than 2 x 2. Can be used
for rectangle table

2
φ
V=
min (r-1), (c-1)

χ2/n
V=
min (r-1), (c-1)

34

34

17
2/10/2020

35

18

You might also like