Sei sulla pagina 1di 94

1

Kandungan

Hypothesis Testing
Comparing two variables using Parametric Tests
‐ Two Independent Samples
‐ Two Related Samples
Comparing two variables using Non‐Parametric Tests
‐ Two Independent Samples
‐ Two Related Samples
Comparing more than two variables using Parametric Tests
‐ Testing for More than Two Independent Samples
‐ Testing for More than Two Related Samples
Comparing more than two variables using Non‐Parametric Tests
‐ Testing for More than Two Independent Samples
‐ Testing for More than Two Related Samples
Chi Square
Correlation and Regression

www.utm.my innovative ● entrepreneurial ● global


1 2
Hypothesis Testing

• The general goal of a


Introduction to hypothesis test is to rule out
chance (sampling error) as a
plausible explanation for the
results from a research study.

• Hypothesis testing is a
technique to help determine
whether a specific treatment
has an effect on the
individuals in a population.

MPPU1034 MPPU1034

3 4
Hypothesis Testing

The hypothesis test is used to


evaluate the results from a
research study in which
1. A sample is selected from
the population.
2. The treatment is
administered to the sample.
3. After treatment, the
individuals in the sample
are measured.

MPPU1034 MPPU1034
5 6
Hypothesis Testing (cont.)

• If the individuals in the sample are noticeably different


from the individuals in the original population, we have
evidence that the treatment has an effect.

• However, it is also possible that the difference between


the sample and the population is simply sampling
error

MPPU1034 MPPU1034

7 8
Hypothesis Testing (cont.)

The purpose of the hypothesis test is to decide between two


explanations:
1. The difference between the sample and the population
can be explained by sampling error (there does not
appear to be a treatment effect)
2. The difference between the sample and the population
is too large to be explained by sampling error (there
does appear to be a treatment effect).

MPPU1034 MPPU1034
9 10
Example 2:

Ho : Tidak terdapat perbezaan


Ho1 : Tidak terdapat perbezaan skor yang signifikan antara jantina.
XXXX yang signifikan antara YYY.

Dependent
Ho2 : Tidak terdapat perbezaan ranking pemilihan universiti antara
Independent
negeri.

Ho3 : Tidak terdapat perbezaan skor yang signifikan antara Ujian Fizik
Ho : Tidak terdapat perbezaan / hubungan dan Ujian Kimia
yang signifikan antara XXXX dan YYY.

dependent dependent

MPPU1034 MPPU1034

Example 2: 11 The Null Hypothesis, the Alpha 12

Level, the Critical Region, and the


Test Statistic
Ho1 : Tidak terdapat hubungan yang signifikan antara gaya kepimpinan
(mengarah) guru besar dengan motivasi guru.

Ho2 : Tidak terdapat hubungan yang signifikan antara gaya kepimpinan


(menyokong) guru besar dengan motivasi guru. The following four steps outline the process of
hypothesis testing and introduce some of the new
Ho3 : Tidak terdapat hubungan yang signifikan antara gaya kepimpinan terminology:
(penglibatan) guru besar dengan motivasi guru.

Ho4 : Tidak terdapat hubungan yang signifikan antara gaya kepimpinan


(orientasi Kejayaan) guru besar dengan motivasi guru.

MPPU1034 MPPU1034
13 14

Step 1

H0: µ1-µ2=0 (treatment has no effect )


H1 : µ1-µ2≠0 (treatment has an effect )

State the hypothesis

The α level establishes a criterion, or "cut-off", for making


a decision about the null hypothesis
MPPU1034 MPPU1034

15 16

Step 2

Locate the critical region.


The critical region consists of outcomes that are very
unlikely to occur if the null hypothesis is true.

MPPU1034 MPPU1034
17 18

Step 3 Step 4
If mean difference is large enough to be significant
Compute the test statistic. in the critical region, we conclude that the REJECT
difference is significant or that the the null hypothesis
The test statistic (in this chapter a z-score) forms a treatment has a significant effect. In this
ratio case we reject the null hypothesis.

If the mean difference is relatively small, Not 


then the test statistic will have a low significant
value. In this case, we conclude that the FAIL TO 
evidence from the sample is not REJECT
sufficient, and the decision is fail to reject the null hypothesis
the null hypothesis.
MPPU1034 MPPU1034

19 20
Learning Check 1 Learning Check 1

An automobile manufacturer claims that a newly introduced model will µ=45 and σ=2. Find Z?
average µ=45 miles per gallon with σ =2. – M=42 for s sample of n=4 ?

A sample of n=4 cars is tested and averages only M=42 miles per = 
gallon. = 
Is this sample mean likely to occur if = 1
the manufacturer’s claim is true?
(Assume that the distribution of the millage
?
Is this sample mean likely to
occur if the manufacturer’s
scores is normal and significant level α=0.05) claim is true?

MPPU1034 MPPU1034
21 22
Some Examples of Null Hypothesis

 Mean of M_Test of Group 1 is equal to mean of M_Test Group 2

H0 : 1 = 2

 Sample mean is equal to the population mean

Some Examples of H0 : =

NULL HYPOTHESIS  The three population means are equal to each other

H0 : 1 = 2 = 2

 The standard deviation of Group A is the standard deviation of


Group B
H0 : 1 =  2

MPPU1034 MPPU1034

23 24
Eg. 1:

Using Table z, identify the critical values need for rejection


of the null hypothesis under the following conditions:

Directionality

one-tailed two-tailed

0.10 1.28 1.65

0.15 1.04 1.44


0.001 3.09 3.30

The structure of a research study to determine whether prenatal alcohol affects


birth weight. A sample is selected from the original population and is given
alcohol. The question is what would happen if the entire population were given
alcohol. The treated sample provides information about the unkonwn treated
population.

MPPU1034 MPPU1034
25 26

Errors in Hypothesis Tests Errors in Hypothesis Tests (cont.)

• Just because the sample mean (following treatment) is • Because the hypothesis test relies on sample data, and
different from the original population mean does not because sample data are not completely reliable, there is
necessarily indicate that the treatment has caused a
change. always the risk that misleading data will cause the
• You should recall that there usually is some discrepancy hypothesis test to reach a wrong conclusion.
between a sample mean and the population mean simply • Two types of error are possible.
as a result of sampling error.

MPPU1034 MPPU1034

27 28

Possible outcomes of a statistical decision Possible outcomes of a statistical decision

MPPU1034 MPPU1034
29 30
Directional Tests Two Types of Hypotheses
The Research Hypothesis or
Alternative Hypothesis (H1)
• When a research study predicts a specific direction for the The hypothesis which states that the
treatment effect (increase or decrease), it is possible to The Null Hypothesis (Ho)
difference between the sample means
incorporate the directional prediction into the hypothesis The hypothesis which states or between the sample mean and the
test. that there is no real difference population mean is real (i.e. the
between the sample means or difference does exist!)
• The result is called a directional test or a one-tailed test. between the sample mean and
H1 : 1  2
A directional test includes the directional prediction in the the population mean
or
statement of the hypotheses and in the location of the H0 : 1 = 2
critical region. H1 : 1 < 2
or

H1 : 1 > 2

Strong Notes: H0 and H1 may involve statistical indexes other than means (refer to examples)!!

MPPU1034 MPPU1034

31 32
Measuring Effect Size
Some Examples of Alternative Hypothesis

 Running time in the 100-metre dash is lower for men than women
• A hypothesis test evaluates the statistical significance of
H1 : males < females
the results from a research study.
• That is, the test determines whether or not it is likely that
 Practice improves test scores the obtained sample mean occurred without any
H1 : pg > cg contribution from a treatment effect.
• The hypothesis test is influenced not only by the size of the
 The relationship between income (X) and education (Y) for treatment effect but also by the size of the sample.
Adsians is different from those live in European communities • Thus, even a very small effect can be significant if it is
H1 : XYAsians  XYEuropeans observed in a very large sample.

MPPU1034 MPPU1034
33 34
Measuring Effect Size

• Because a significant effect does not necessarily mean a


Cohen’s d uses the  large effect, it is recommended that the hypothesis test be
standard deviation 
to help measure 
accompanied by a measure of the effect size.
effect size. • We use Cohen’s d as a standardized measure of effect
size.
• Much like a z-score, Cohen’s d measures the size of the
mean difference in terms of the standard deviation.

MPPU1034 MPPU1034

35 36
Power of a Hypothesis Test Power of a Hypothesis Test

• The power of a hypothesis test is defined is the probability


that the test will reject the null hypothesis when the
treatment does have an effect.
Cohen’s d =
• The power of a test depends on a variety of factors
including the size of the treatment effect and the size of the
sample.

MPPU1034 MPPU1034
37 38

• As you can see, there is


considerable overlap between the
two distribution even when
Cohen’s d indicates a large effect.
• This means that even for large
d= effects there will be many
individuals that go against the
d = 1.00 population-level pattern.
• Always keep these types of
figures in mind when trying to
interpret effect size measures.

MPPU1034 MPPU1034

39 40
Power of a Hypothesis Test
Interpretation
1. Cohen’s d = 0.2 ( small effect)
2. Cohen’s d = 0.5 ( medium effect)
Cohen’s  d
Percentage of variance accounted , 3. Cohen’s d = 0.8 ( Large effect)

1. r2=0.01 (Small effect)


2. r2=0.09 (Medium effect)
Percentage of 
3. r2=0.25 (Large effect) variance accounted,

MPPU1034 MPPU1034
41 42
How to write hypothesis?

MPPU1034 MPPU1034

43 44
test your knowledge.. test your knowledge..
We always test a null hypothesis against an
1 alternative. The alternative hypothesis states that there is no
3 difference/no effect.
A. True
B. False A. True
ANSWER: A B. False

Statistical power tells us our level of Type I error.


2
A. True
B. False
ANSWER: B
MPPU1034 MPPU1034
45 46
test your knowledge.. test your knowledge..

4 If our sample value is close to the null/population value, Type I error occurs when we
we conclude that
5
A. correctly fail to reject a false null hypothesis.
A. we can neither accept or reject the null. B. correctly reject a false null hypothesis.
B. something happened in the study; there is a C. incorrectly reject a false null hypothesis.
significant effect. D. incorrectly reject a true null hypothesis.
C. nothing happened in the study; there is no effect. ANSWER: D
D. something happened in the study, but the effect is
very small.

MPPU1034 MPPU1034

47 How to Interpret Result From 48


test your knowledge.. SPSS?
Hypothesis
6 = No Diff between score pre and post..
0.05
In hypothesis testing, what is the null hypothesis?
A. a statement of what the experiment is trying to prove or show, by
applying some kind of treatment on one or more variables
B. a statement of the probability of obtaining the experimental results
purely by chance
C. a statement of the validity of the experiment
D. a statement of no difference from what one would normally expect if
there were no effect of the experimental treatment If Sig, p > 0.05  Fail to Reject , No Diff 
E. a statement of the relative effectiveness of a treatment applied to a If Sig, p  0.05  Reject , Have Diff
randomly selected group of subjects From table, the p-value @ sig value is 0.004. We reject the
null hypothesis, and conclude that the data Sig Diff

MPPU1034 MPPU1034
49 50
Example: Example:
1
2

MPPU1034 MPPU1034

51

MPPU1034
1 2

Parametric VS Non-Parametric

T-test Parametric Non‐Parametric

Ratio / Interval Ordinal / Nominal

Mean Median

Pearson Spearman

Independent t‐test Mann‐Whitney test

One‐way independent ANOVA Kruskal‐Wallis test

Paired t‐test Wilcoxon test

One‐way repeated ANOVA Friedman’s test

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

3 4

The t Test T-Test Assumptions

One Sample T‐Test Measurement scales

Dependent Sample T‐Test Normality

Independent Sample T‐Test Homogeneity of variance

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


5
5 6

The t Test
One Sample T‐Test
- Known
- Compare with sample

vs 119,108,134,140,98,87,88, 97, ……
̅ 110 /

Populasi
/ Adakah terdapat
perbezaan halaju sampel
berbanding populasi?

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

7 8
7 8
The Estimated Standard Error and
The t Test For One Sample
the t Statistic
• The hypothesis test allows researchers to evaluate the
mean difference between known population mean
(variance remain unknown) using the data from a single
sample.

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


9 10
9 10

Example of One Sample t-test


A sample of n=25 individuals is randomly selected from
population with a mean of µ =65, and a treatment is
administered to the individuals in the sample. After treatment
the sample mean is found to be M=70.
a) If the sample standard b) If the sample standard
deviation is s =10, are the deviation is s=20, are the data
data sufficient to conclude sufficient to conclude that the
that the treatment has a treatment has a significant
significant effect using a two- effect using a two-tail test with
tail test with α =0.05? α =0.05?

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

11 12
11 12

Example of One Sample t-test


1. State the hypothesis
n = 25 H0 :     = 65
(a)
µ =65 t=M-µ
H1 :   65
SM
M=70 2. Find the critical value with α = 0.05 and df= n ‐ 1
t = 70 – 65
2

t = 2.5

4. Make decision 
(b) ???

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


13 14
13 14

Example : Manual
Mean, M 71.3
n= 10 Standard Deviation, s 15.853

67, 54, 78, 95, 56, 78, 44, 78, 76, 87 Standard Error, SM 5.013

Given , population mean = 65


Testing value
Mean ?
Standard Deviation ?

Standard Error ?

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

15 16
15 16

Result Result
1. State the hypothesis 2. Find the critical value with α = 0.05 and df= n ‐ 1
H0 :     = 65 df = 9
H1 :   65 From Table

‐ 2.262 + 2.262

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


17 18
17 18

Result Result
3. Compute t 4. Make decision 
Fail to Reject hypothesis Null
t and

Compute, t = 71.3 – 65
71.3 – 65
‐ 2.262 + 2.262
5.013
5.013
= 1.256
1.256

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

19 20
19 20
Test/ Computer..
Using SPSS for population mean of 65 at alpha
0.05

Spss view

Compare 0.241 with 0.05

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


21 22
21 22

Result; Self Check

Fail to Reject hypothesis Null score: 4,4,3,2,5,1,1,4

Is there any significant different when


µ=5.5 at α=0.05? 71.3 – 65
‐ 2.365 + 2.365
5.013

‐4.677

Result : Reject H0
www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

23 24
23 24

How to get this from SPSS??

SPSS
The t Test For
One Sample

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


25 26
25 26

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

27 28
27 28

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


29
29

www.utm.my  innovative ● entrepreneurial ● global


1 2

The t Test For


Two Independent Samples
One Sample T‐Test

Independent Sample T‐Test

47%
53% Male Dependent Sample T‐Test
Female

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

3 4

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


5 6
Two Independent Samples
Two Independent Samples
A sample of two group Male and Female in Biology Quiz in df = n-1
one of the school. The data are as follows:

Female 10,8,7,9,13,7,6,12 2. Find the critical value with α = 0.05 and df= df1 + df2


Male 7, 4,9,3,7

a) Is the score of Female is better than Male at α = 0.05?

b) Calculate the value of r2 for these data.


4. Make decision  

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

7 8
Two Independent Samples Two Independent Samples

2. Find the critical value with α = 0.05 and df= df1 + df2
df = df1 + df2 = (8-1) + (5-1) = 7 + 4
df = 11

71.3 – 65 + 2.201
5.013

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


9 10
Two Independent Samples From calculator
Two Independent Samples
3.  Compute, t 4. Make decision  
n
M@/

t   =   2.117

71.3 – 65 2.201
5.013
2.117

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

11 12
SPSS…

Value of Sig, p >

Fail to reject hypothesis Null


Is the score of Female is better than Male? No
www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global
13 14

= 9-6 (2.117)2
=
2.4494922 + 2.507132
(2.117)2 + 11
2
= 0.289
= 1.216

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

15 16

cth
1. Cohen’s d = 0.2 ( small effect)
2. Cohen’s d = 0.5 ( medium effect) SPSS
3. Cohen’s d = 0.8 ( Large effect)
t-TEST
1. r=0.01 (Small effect) Independent sample
2. r=0.09 (Medium effect)
3. r=0.25 (Large effect)

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


17 18

• Jantina
– Independent
• Markah Fizik
– dependent
• Markah Math
– dependent

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

19 20

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


21

Independent Samples Test

Levene's Test for Equality of 
Variances t‐test for Equality of Means

95% Confidence Interval of 

Mean  Std. Error  the Difference

F Sig. t df Sig. (2‐tailed) Difference Difference Lower Upper

UJIAN FIZIK Equal variances 
.575 .456 ‐.406 23 .688 ‐3.567 8.779 ‐21.728 14.595
assumed

Equal variances not 
‐.412 20.347 .685 ‐3.567 8.658 ‐21.607 14.474
assumed

UJIAN MATEMATIK Equal variances 
.236 .631 .561 23 .580 5.233 9.332 ‐14.072 24.538
assumed

Equal variances not 
.577 21.187 .570 5.233 9.076 ‐13.630 24.097
assumed

Fail to reject hypothesis Null


www.utm.my  innovative ● entrepreneurial ● global
1 2
Repeated‐measures Designs
The related‐samples hypothesis test allows researchers to
evaluate the mean difference between two treatment
The T Test For conditions using the data from a single sample.
Two Related In a repeated‐measures design, a single group of
individuals is obtained and each individual is measured in
Samples both of the treatment conditions being compared.
Thus, the data consist of two scores for each individual.

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

3 4
Hypothesis tests with the Hypothesis tests with the
repeated‐measures repeated‐measures
The repeated‐measures t statistic allows
researchers to test a hypothesis about the In this situation it is possible to compute a
population mean difference between two difference score for each individual:
treatment conditions using sample data from a difference score = D = X2 – X1
repeated‐measures research study.
Where X1 is the person’s score in the first
treatment and X2 is the score in the second
treatment.
Or
Where X1 is the person’s score in the pre‐test
(before treatment) and X2 is the score in the post‐
test (after treatment).

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


Hypothesis Tests With Matched‐ 5
Hypothesis Tests With The 6

subjects Design Repeated‐measures


Thus, the data consist of pairs of scores with each
The related‐samples t pair corresponding to a matched set of two
test can also be used for "identical" subjects.
a similar design, called a
For a matched‐subjects design, a difference score is
matched‐subjects
computed for each matched pair of individuals.
design, in which each
individual in one
treatment is matched
one‐to‐one with a
corresponding
individual in the second
treatment.
www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

Hypothesis Tests with the


7
Hypothesis Tests With The 8

Repeated‐Measures Repeated‐measures

• The sample of difference scores is used to


test hypotheses about the population of
difference scores. The null hypothesis
states that the population of difference
scores has a mean of zero,

H0: μD = 0

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


Hypothesis Tests With The 9
Hypothesis Tests With The 10

Repeated‐measures Repeated‐measures
In words, the null hypothesis says that there is no
consistent or systematic difference between the two
treatment conditions.

Note that the null hypothesis does not say that


each individual will have a difference score equal to
zero.
Some individuals will show a positive change from one
treatment to the other, and some will show a negative
change.

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

11 12
Hypothesis Tests with the Example Of Repeated‐measures
Repeated‐Measures Designs

• Effect size for the independent‐measures t is The following data demonstrate these points:
measured in the same way that we measured
Subject X1 X2 D
effect size for the single‐sample t and the
independent‐measures t. A 9 16 ?
• Specifically, you can compute an estimate of B 25 28 ?
Cohen’s d to obtain a standardized measure of the
mean difference, or you can compute r2 to obtain a C 31 36 ?
measure of the percentage of variance accounted D 58 61 ?
for by the treatment effect.
E 72 79 ?

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


Example of Two Related 13 Example of Two Related 14

Samples Samples
1

2. Find the critical value with α = 0.05 and df= n‐1

4. Make decision 

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

Example of Two Related 15 Example of Two Related 16

Samples Samples

12. Find the critical value with α = 0.05 and df= n ‐ 1 3 S=2

df = 4
From Table
SS = 141 – 252 SMD = 0.894
5
‐ 2.776 + 2.776 SS = 16 t= 5–0
0.894
MD t = 5.593

‐ 2.776 + 2.776

5.593

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


Example of Two Related 17 18

Samples Using SPSS…

4 Make decision..
Reject hypothesis Null
‐ 2.776 + 2.776

5.593

Reject null hypothesis

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

19 SPSS 20
Example of Repeated‐ The t Test for Two Related Samples
Measures Designs
• Notice that the original data show big differences
from one treatment to another. 1

• These big individual differences are eliminated


when the difference scores are calculated.
• Because the individual differences are removed, 2
the D scores are usually much less variable than
the original scores.
• Again, a smaller variance will produce a smaller
standard error, which will increase the likelihood
of a significant t statistic. 3

4
www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global
21 22
Pastikan anda dapat menterjemah
setiap nilai yang ditunjukkan…
Kesimpulan?
1 p > α  Gagal menolak Ho, Tidak terdapat perbezaan yang signifikan
Ambil 
2
3 Perhatian p < α  Ho ditolak, Terdapat Perbezaan yg signifikan
p = Sig.
• p = 0.005
4 5 6 • p < α
11 • @ p < 0.05 , maka Ho ditolak.
Terdapat perbezaan yang
9
7
8 10
signifikan antara skor X1 dan
X2

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

23

www.utm.my  innovative ● entrepreneurial ● global


1 2
Parametric VS Non‐
Parametric

Mann-Whitney U Test Parametric Non‐Parametric

Ratio / Interval Ordinal / Nominal

Mean Median

Pearson Spearman
Parametric : Data
Interval/ Independent t‐test Mann‐Whitney test
ratio
Normal One‐way independent ANOVA Kruskal‐Wallis test
distribution Non Parametric
Paired t‐test Data : Ordinal/Wilcoxon test
Not Normal 
One‐way repeated ANOVA distribution Friedman’s test

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

3 4

• Uses ordinal data from two separate


Non parametric samples to test a hypothesis about the
difference between two population or
Independent Sample two treatment condition.
Mann‐Whitney U Test • Alternative to the independent
measures t test in situations where
the data can be ranked.

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


5 6

Hipotesis ..

Ho1 : Tidak terdapat perbezaan pilihan (s1) antara jantina


Ho2 : Tidak terdapat perbezaan pilihan (s2) antara jantina
Ho3 : Tidak terdapat perbezaan pilihan (s3) antara jantina

1 = Lelaki
2 = perempuan
Latihan1Q3.sav

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

7 8

1 = Lelaki
6 2 = perempuan
7 9
2

8
3

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


9 10

Output Kesimpulan?
p > α  Gagal menolak Ho, Tidak terdapat perbezaan yang signifikan
2
1 3 p < α  Ho ditolak, Terdapat Perbezaan yg signifikan
p = Asymp.Sig.

Ambil 
Bagi s1;
Perhatian • p = 0.772
• p > α
• @ p > 0.05 , maka Ho GAGAL
4
ditolak. Tidak terdapat
perbezaan yang signifikan
antara pilihan yang dibuat.
5
www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

11

www.utm.my  innovative ● entrepreneurial ● global


1 2

• Uses the data from a repeated‐measures or


matched‐samples
Non parametric • Design to evaluate the difference between
For two related sample two treatment condition
• Alternative to the related t test in situation
Wilcoxon Test in which the sample data (difference scores)
can be ranked.

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

3 4
1
Contoh

Kajian dilakukan
untuk melihat
adakah terdapat
perbezaan pilihan
bagi calon yang
memilih UTM 2

berdasarkan pilihan
3
mereka sebelum dan
selepas taklimat
diberikan.
4

Latihan1Q5.sav

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


5 6
1
2

5
3 4 5

7 5
Ambil 
Perhatian
6 6

9
7

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

7 8

Kesimpulan?
p > α  Gagal menolak Ho, Tidak terdapat perbezaan yang signifikan
p < α  Ho ditolak, Terdapat Perbezaan yg signifikan
p = Asymp Sig.
• p = 0.008
• p < α
• @ p < 0.05 , maka Ho ditolak.
Terdapat perbezaan yang
signifikan antara pilihan
sebelum dan selepas taklimat

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


Comparing more than two variables using Parametric Tests 2

ANOVA 
Analysis of Variance

ANOVA – Independent samples

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

3 4
The Logic and the Process of
Analysis of Variance
• ANOVA can be used in situations where there

are two or more means being • ANOVA allows researcher to evaluate all
compared, whereas the t tests are limited to
only two means are involved.
ANOVA vs t-test
of the mean differences in a single
• These situations would require a series of hypothesis test using a single α‐level
several t tests to evaluate all of the mean and, thereby, keeps the risk of a Type I
differences. (t test can compare only 2 means error under control no matter how many
at a time.) different means are being compared.
• Although each t test can be done with a specific
α‐level (risk of Type I error), the α‐levels
accumulate over a series of tests so that
the final experimentwise α‐level can be quite
large
www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global
5 6

• The test statistic for ANOVA is an F‐ratio, which is a


ratio of two sample variances. In the context of
ANOVA, the sample variances are called mean
squares, or MS values.

• The top of the F‐ratio MSbetween measures the size of


mean differences between samples. The bottom of
the ratio MSwithin measures the magnitude of
differences that would be expected without any
treatment effects.

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

7 8
The structure and sequence of calculations for the ANOVA.

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


9 10
The Logic and the Process of
Analysis of Variance (cont.)

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

11 12
Example Steps
One experiment call examining learning performance 1. State the hypothesis
under three temperature condition (GroupA1, GroupA2,
Ho: µ1= µ2= µ3  
Group A3). The dependent variable is the number of
problem solved correctly. H1: At least one of the treatment means is different.
Temperature conditions 2. Find the critical value with α = 0.05 and F(between, within)
Is there any 
A1 ‐ 50o A2 ‐70o A3‐ 90o significant 
0 4 1 different between 
three groups at 
1 3 2
alpha 0.05?
3 6 2
1 3 0
4. Make decision
0 4 0

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


13 14
Example 1 Example
Temperature conditions
A1 ‐150o A2 ‐702 o 3 o
A3‐ 90
Temperature conditions
0 4 1
A1 ‐ 50o A2 ‐70o A3‐ 90o
1 3 2 G=30 G = T1 + T2 + T3
0 4 1
3 6 2
1 3 2
1 3 0
N=15 N = n1 + n2 + n3
3 6 2
0 4 0 k=3
1 3 0
T1=5 T2=20 T3=5
0 4 0
SS1=6 SS2=6 SS3=4
n1=5 n2=5 n3=5

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

Source SS df MS F 15 16

Between SSbetween dfbetween


subject subject
Within SSwithin dfwithin
treatment
Total SStotal dftotal

Draw
Anova table ?

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


17 18

SPSS OUTPUT SPSS OUTPUT


ANOVA ANOVA

Sum of Sum of
Squares df Mean Square F Sig. Squares df Mean Square F Sig.
Between Groups Between Groups
30.00 2 15.00 11.25 .002
Within Groups Within Groups
16.00 12 1.33
Total Total
46.00 14

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

19
Analysis of Variance 20

and Post Tests

• The null hypothesis for ANOVA states that for the


general population there are no mean differences
among the treatments being compared; H0: μ1 = μ2
= μ3 = . . .
• When the null hypothesis is rejected, the
conclusion is that there are significant mean
differences.
• However, the ANOVA simply establishes that
differences exist, it does not indicate exactly which
treatments are different.

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


Analysis of Variance 21
Post ‐Hoc 22

and Post Tests


• With more than two treatments, this creates a
problem. Specifically, you must follow the ANOVA
with additional tests, called post tests, to
determine exactly which treatments are different
and which are not.
• The Scheffe test and Tukey=s HSD are examples
of post tests.
• These tests are done after an ANOVA where H0 is
rejected with more than two treatment conditions.
The tests compare the treatments, two at a time, to
test the significance of the mean differences.

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

23 24
Measuring Effect Size for an Measuring Effect Size for an
Analysis of Variance Analysis of Variance

• To supplement the hypothesis test, it is • For the t statistics, this percentage was identified
recommended that you calculate a measure of as r2, but in the context of ANOVA the percentage is
effect size. identified as η2 (the Greek letter eta, squared).
• For an analysis of variance the common technique • The formula for computing effect size is:
for measuring effect size is to compute the
percentage of variance that is accounted for by the SSbetween treatments
treatment effects. η2 = ───────────
SStotal

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


25 26
Measuring Effect Size for an Example 2
Analysis of Variance

8438.641
η2 = ─────────── = 0.183 Treatment
46122.166 A B C
2 3 7
6 7 5
2 6 4
6 4 8

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

27 Source SS df MS F 28
Example 2
Between SSbetween dfbetween
Treatment Within
subject
SSwithin
subject
dfwithin
A B C treatment

2 3 7 Total SStotal dftotal


G=60
6 7 5 N=12
2 6 4
k=3
6 4 8
T1=16 T2=20 T3=24
SS1=16 SS2=10 SS3=10
n1=4 n2=4 n3=4

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


29 30

One Way Anova SPSS OUTPUT


Source SS df MS F
ANOVA
Between SSbetween dfbetween
subject subject
ANSWER
Within SSwithin dfwithin Sum of  Mean 
Squares df Square F Sig.
treatment Between 
Groups
Total SStotal dftotal
Within Groups

Total

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

31 32

SPSS OUTPUT
ANOVA
ANSWER
Sum of  Mean 
Squares df Square F Sig.
Between 
Groups 8 2 4 1 0.405
Within Groups
36 9 4
Total
44 11

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


33 34

ANOVA TABLE
ANOVA TABLE
ANSWER ANSWER
Sum of  Mean  Sum of  Mean 
Squares df Square F Squares df Square F
Between  Between 
Groups Groups 468.7 2 234.35 28.53
Within Groups Within Groups
345 42 8.21
Total Total
813.7 44

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

35 36

Ho: Tidak terdapat


perbezaan markah
pensyarah yang
ANOVA signifikan antara
Independent‐measures program

Latihan1Q2.sav
www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global
37 38

1
2

3 5

4
6

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global

39 40

1 2

10
Ambil 
Perhatian

4
5 6 7
3

www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global


41 42

Kesimpulan?
p > α  Gagal menolak Ho, Tidak terdapat perbezaan yang signifikan
p < α  Ho ditolak, Terdapat Perbezaan yg signifikan

• p = 0.000 p = Sig.

• p < α
• @ p < 0.05 , maka Ho ditolak. Terdapat perbezaan
markah pensyarah yang signifikan antara
program. Perbezaan ini wujud antara program
‐ SPA dengan SPE
‐ SPA dengan SPS
‐ etc
www.utm.my  innovative ● entrepreneurial ● global www.utm.my  innovative ● entrepreneurial ● global
2
The Logical Background for a
Repeated‐Measures ANOVA

Analysis of Variance
• The repeated‐measures design eliminates
individual differences from the
between‐treatments variability because the same
subjects are used in every treatment condition.
• The result is a test statistic similar to the
independent‐measures F‐ratio but with all
Repeated‐Measures individual differences removed.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

Comparing Independent‐ 3 Comparing Independent‐ 4


Measures and Repeated‐ Measures and Repeated‐Measures
Measures ANOVA ANOVA

• The independent‐measures analysis is used in • What makes the repeated‐measures analysis


research situations for which there is a separate different from the independent‐measures analysis is
sample for each treatment condition. the treatment of variability from individual
• The analysis compares the mean square (MS) differences. The independent‐measures F ratio
between treatments to the mean square within (Chapter 13) has the following structure:
treatments in the form of a ratio MS between treatments treatment effect + error (including individual differences)
MS between treatments F = ──────────── = ───────────────────────────────────
MS within error (including individual differences)
F = ───────────
• In this formula, when the treatment effect is zero (H0
MS within treatments true), the expected F ratio is one.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


Comparing Independent‐ 5 Comparing Independent‐ 6
Measures and Repeated‐Measures Measures and Repeated‐Measures
ANOVA ANOVA
• In the repeated‐measures study, there are no
individual differences between treatments • That is, we want the repeated‐measures F‐
because the same individuals are tested in every
treatment.
ratio to have the following structure:
• This means that variability due to individual
differences is not a component of the numerator of treatment effect + error (without individual differences)
the F ratio. F = ────────────────────────────────────
error (with individual differences removed)
• Therefore, the individual differences must also be
removed from the denominator of the F ratio to
maintain a balanced ratio with an expected value
of 1.00 when there is no treatment effect.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

Comparing Independent‐ 7 Comparing Independent‐ 8


Measures and Repeated‐Measures Measures and Repeated‐Measures
ANOVA ANOVA
• This is accomplished by a two‐stage analysis. In • In the second stage of the analysis, we
the first stage, total variability (SS total) is
partitioned into the between‐treatments SS and measure the individual differences by
within‐treatments SS. computing the variability between subjects,
• The components for between‐treatments or SS between subjects
variability are the treatment effect (if any) and
error. • This value is subtracted from SS within leaving
• Individual differences do not appear here because a remainder, variability due to experimental
the same sample of subjects serves in every
treatment. On the other hand, individual error, SS error
differences do play a role in SS within because the
sample contains different subjects.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


9 10

Example 1

Participant 24H 36H 48H


A 0 0 6
B 1 3 5
C 0 1 5
D 4 5 9
E 0 1 5

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

11 12
Steps
1. State the hypothesis
Ho: µ1= µ2= µ3  
H1: At least one of the treatment means is different.
2. Find the critical value with α = 0.05

4. Make decision

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


13 14

Example 1

Participant 24H 36H 48H P Total


A 0 0 6 6 N=15
B 1 3 5 9 G=45
C 0 1 5 6
D 4 5 9 18
E 0 1 5 6
T 5 10 30
SS 12 16 12

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

15 16

ANOVA table ANOVA table

Source SS df MS F Source SS df MS F
Between SSbetween dfbetween Between

Within SSwithin dfwithin Within

Between Subject Ssbetween subject  dfbetween subject Between Subject

Error SSerror dferror Error

Total
Total SStotal dftotal

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


17 18

ANOVA table SPSS


Tests of Within‐Subjects Effects

Source SS df MS F Measure:MEASURE_1

Between 70 2 35 70 Type III Sum Mean


Source of Squares df Square F Sig.
factor1 Sphericity
70.000 2 35.000 70.000 .000
Within 40 12 Assumed
Greenhouse‐
70.000 1.000 70.000 70.000 .001
Geisser
Between Subject 36 4 Huynh‐Feldt 70.000 1.000 70.000 70.000 .001
4 Lower‐bound 70.000 1.000 70.000 70.000 .001
Error 8 0.5
Error(factor1) Sphericity
4.000 8 .500
Total 110 14 Assumed
Greenhouse‐
4.000 4.000 1.000
Geisser
Huynh‐Feldt
4.000 4.000 1.000
Lower‐bound
4.000 4.000 1.000

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

19 20

Example 2 Example 2
Depression Scores
Sample Before Therapy After Therapy 6 Month  Person 
Depression Scores Follow up Total
Sample Before Therapy After Therapy 6 Month  A 71 53 55 179 n=5
Follow up
B 62 45 44 151 K=3
A 71 53 55
C 82 56 61 199 N=15
B 62 45 44
D 77 50 46 173 G=892
C 82 56 61
E 81 54 55 190
D 77 50 46
T=373 T=258 T=261
E 81 54 55
SS=273.2 SS=73.2 SS=198.8

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


21 22

ANOVA table ANOVA table

Source SS df MS F Source SS df MS
Between SSbetween dfbetween Between

Within SSwithin dfwithin Within

Between Subject Ssbetween subject  dfbetween subject Between Subject

Error SSerror dferror Error

Total
Total SStotal dftotal

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

23 24
Measuring Effect Size for the
ANOVA table Repeated‐Measures Analysis of
Variance
Source SS df MS The formula for computing effect size for a repeated‐measures
Between 1718.5 2 859.25 69.6 ANOVA is:

Within 545.2 12 SS between treatments SS between treatments


η2 = ───────────── = ──────────────
Between Subject 446.4 4
SS total ‐ SS between subjects SS error + SS between treatments
Error 98.8 8 12.35
Total 2263.7 14

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


26

Ho:‐ Tidak terdapat


SPSS perbezaan skor
pencapaian pelajar
ANOVA dalam ujian‐ujian yang
diduduki.
Repeated‐Measures

Latihan3Q1.sav

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

27 28

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


29 30

Kesimpulan?
p > α  Gagal menolak Ho, Tidak terdapat perbezaan yang signifikan
p < α  Ho ditolak, Terdapat Perbezaan yg signifikan
p = Sig.

• p = 0.000
• p < α
@ p > 0.05 , maka Ho ditolak. Terdapat
perbezaan skor pencapaian pelajar dalam
ujian‐ujian yang diduduki.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

31
31

www.utm.my innovative ● entrepreneurial ● global


1 2

Non parametric Kajian dilakukan untuk


Independent‐measured melihat adakah terdapat
perbezaan pilihan
Kruskal‐Wallis Test
universiti antara empat
For ordinal data kumpulan.

Lebih dari 2  1 data ordinal/
kumpulan /  Dependent
independent

Latihan1Q6.sav

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

3 4

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


5 6

Kesimpulan?
p > α  Gagal menolak Ho, Tidak terdapat perbezaan yang signifikan
p < α  Ho ditolak, Terdapat Perbezaan yg signifikan
p = Asymp Sig.
• p = 0.470
• p > α
• @ p > 0.05 , maka Ho GAGAL
ditolak. Terdapat perbezaan
pilihan yang signifikan antara
kumpulan

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

7
7

www.utm.my innovative ● entrepreneurial ● global


1 2

SPSS‐Ordinal data

SPSS • Uses ordinal data from three or more


treatment condition to test a hypothesis
Non Parametric
about the differences between three or
Repeated‐Measures more populations (or treatment condition)
Friedman Test • Alternative to the repeated measure ANOVA
in situations in which the data can be rank‐
ordered.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

3 4

Sampel

Ho: Tidak terdapat


perbezaan pilihan
yang dibuat antara
penyataan soalan
1‐ 5.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


5 6

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

8
7 8

Kesimpulan?
p > α  Gagal menolak Ho, Tidak terdapat perbezaan yang signifikan
p < α  Ho ditolak, Terdapat Perbezaan yg signifikan
p = Asymp Sig.
• p = 0.000
• p < α
• @ p > 0.05 , maka Ho ditolak.
Perdapat perbezaan pilihan
yang dibuat antara penyataan
soalan 1‐ 5.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


2

Non Parametric Goal Parametric Non parametric 


Median, interquartile 
Describe one group Mean, SD
range
Compare one group to a 
One‐sample t‐test Wilcoxon test
hypothetical value

Compare two unpaired groups Unpaired t test Mann‐Whitney test

Compare two paired groups Paired t test Wilcoxon test

Compare three or more unmatched 
One‐way ANOVA Kruskal‐Wallis test
groups
Compare three or more matched 
Repeated‐measures ANOVA Friedman test
groups
Quantify association between two 
Pearson correlation Spearman correlation
variables

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

3 4

Chi‐square Test Nonparametric Tests

Non‐parametric hypothesis tests


(distribution free test) using the chi‐square
statistic:
1. the chi‐square test for goodness of fit
2. the chi‐square test for independence.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


5
The Chi‐Square Test 6
Nonparametric Tests
for Goodness‐of‐Fit
• The chi‐square test for goodness‐of‐fit uses
frequency data from a sample to test hypotheses
about the shape or proportions of a population.
• The data, called observed frequencies, simply
count how many individuals from the sample are
in each category. (eg. How many choose Likert
scale no. 4)

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

The Chi‐Square Test 7 8


How to compare?
for Goodness‐of‐Fit
• The null hypothesis specifies the proportion
of the population that should be in each
category.
• The proportions from the null hypothesis
are used to compute expected frequencies 21
that describe how the sample would appear 3
if it were in perfect agreement with the null 12
hypothesis. 4

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


9 10
Nominal Data EXAMPLE‐ Goodness‐of‐Fit

Independent  Dependent 
variables variables

YES NO
GROUP A 16 34
GROUP B 7 43

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

12
11 12

Example‐ Goodness‐of‐Fit Goodness‐of‐Fit


A survey of 50 respondent to choose 
preferable view of their future houses. 1. State the hypothesis
Ho: No preference for any specific view
Lake view Sea view River view Town view H1: One or more specific view is preferred
18 17 7 8

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


13 14
13 14

Goodness‐of‐Fit Goodness‐of‐Fit

1. State the hypothesis


Ho: No preference for any specific view
H1: One or more specific view is preferred

Lake view Sea view River view Town view Lake   Sea  River  Town 


25% 25% 25% 25% view view view view
Observed frequency 18 17 7 8
Expected frequency 12.5 12.5 12.5 12.5

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

15 16
15 16

Goodness‐of‐Fit Goodness‐of‐Fit

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


17 18

Goodness‐of‐Fit

CHI SQUARE
Goodness‐of‐Fit

4. Make decision
Reject hypothesis Null 
www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

19 20

SPSS

Ho: Tidak terdapat


perbezaan pilihan view oleh
pembeli rumah.

Recode kpd Numeric

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


21 22

Keptusan?

• p = 0.044
• p < α
• @ p < 0.05 , maka Ho
ditolak. Terdapat
perbezaan pilihan view
oleh pembeli rumah.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

23 24

Lake view Sea view River view Town view


Bagaimana jika data 18 17 7 8
dikutip dalam bentuk
frekuensi..

Data Structure On 
Spss

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


25 26

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

27 28

SPSS
Output

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


29 30

Decision

The respondent showed


significant
The Chi‐Square Test for Independence 
preference among the four views.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

The Chi‐Square Test for 31


The Chi‐Square Test for 32

Independence Independence
The second chi‐square test, the chi‐ A frequency distribution showing willingness to
square test for independence, can use mental health service according to gender
be used and interpreted in two for a sample of 150
different ways: Willingness to use Mental Health Service
a) Testing hypotheses about the Probably No Maybe Probably yes
relationship between two Male 17 32 11
variables in a population, or Female 13 43 34

b) Testing hypotheses about


differences between proportions
for two or more populations.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


The Chi‐Square Test for 33 34

Version 1:
Independence
A frequency distribution showing willingness to
Ho : In the general population, there is no use mental health service according to gender
relationship between gender and for a sample of 150
willingness to use mental health service.
Willingness to use Mental Health Service
Probably No Maybe Probably yes
Version 2
Male 17 32 11 60
Ho : In the general population, the  Female 13 43 34 90
30 75 45 N=150
distribution of reported willingness to use 
mental health service is the same for male and 
female.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

36
35 36

Willingness to use Mental Health Service
Probably No Maybe Probably yes
Willingness to use Mental Health Service
Male 17 (12) 32 (30) 11 (18) 60
Probably No Maybe Probably yes
Female 13 (18) 43 (45) 34 (27) 90
Male 17 (12) 32 (30) 11 (18) 60
30 75 45 N=150
Female 13 (18) 43 (45) 34 (27) 90
20% 50% 30%
30 75 45 N=150
20% 50% 30%
=30/150*100

=75/150*100

=45/150*100 =30% from 90 =30% from 60

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


The Chi‐Square Test for 37 38

Version 1:
Independence R=Row = (2‐1)(3‐1)
C=Column

Ho  : In the general population, there is no  2
1
relationship between gender and 
willingness to use mental health service.
3 Compute 
H1: In the general population, there is a consistent 
predictable relationship between gender and 
willingness to use mental model service.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

39 40

Table 
5.99 Calculation
8.23

SPSS
CHI SQUARE
Reject H0
4 Or
There is a significant relationship for Independence
between gender and willingness to use
mental model service.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


41 42
Bagaimana input data dalam
SPSS? SPSS
Willingness to use Mental Health 
Service
1Probably No Maybe 2 Probably yes3
Male 1 17 32 11
Female 2 13 43 34

1 1 17
1 2 32

1 3 11

2 1 13

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

43 44

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


45 46

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

47 48

Keputusan?

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


49

www.utm.my innovative ● entrepreneurial ● global


2

Correlation 
Y
Y = mX + c ??

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

3 4
Correlations: Measuring and
Describing Relationships

• A correlation is a statistical
method used to measure and
describe the relationship between
two variables.
• A relationship exists when
changes in one variable tend to be
accompanied by consistent and
predictable changes in the
other variable.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


5 6
Correlations: Measuring and
Describing Relationships

• A correlation typically
evaluates three aspects
of the relationship:
the 
degree

the 
form
the 
direction

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

7 8
Correlations: Measuring and Correlations: Measuring and
Describing Relationships Describing Relationships

• The direction of the relationship is measured by


the sign of the correlation (+ or ‐). A positive
correlation means that the two variables tend to
change in the same direction; as one increases, the
other also tends to increase.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


9 10
Correlations: Measuring and Correlations: Measuring and
Describing Relationships Describing Relationships

• The most common form of relationship


is a straight line or linear relationship
which is measured by the Pearson
correlation.

relationships that are not linear

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

11 12
Correlations: Measuring and
Describing Relationships

• The degree of relationship 1.00


perfect
(the strength or consistency of relationship
the relationship) is measured
by the numerical value of the
correlation. A value of 1.00
indicates a perfect relationship
and a value of zero indicates no
relationship.
0.00
no relationship.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


13 14

a perfect negative  ??
correla on, −1.00 no linear 
trend, 0.00

a relatively weak 
negative correlation, 
approximately −0.40

a strong positive 
relationship, 
approximately 
+0.90
www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

15 16
Examples of positive and
negative relationships.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


17 18
Correlations: Measuring and
Describing Relationships The Pearson Correlation
• To compute a correlation you need
two scores, X and Y, for each
individual in the sample.
• The Pearson correlation requires
that the scores be numerical
values from an interval
or ratio scale of
measurement.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

19 20

Example Scatter plot

Student X Y
A 0 4
B 2 1
C 8 10
D 6 9
E 4 6

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


21 22
Find r
HIPOTESIS

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

23 24

Reporting SPSS

• A correlation for the data revealed that


score subject X and score subject Y were not
significantly related, r=0.86, n=5 , α = 0.05
two tails.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


25 26
EXAMPLE 2: Question 14 pg#559 Scatter Plot
Student X Y

A 11 14
B 6 7
C 16 15
D 4 7
E 1 3
F 10 9
G 5 9
H 3 8

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

27 28

SPSS
Correlations

XX YY
XX Pearson Correlation
1 .904**
Sig. (2‐tailed)
.002
N
8 8
YY Pearson Correlation
.904** 1
Sig. (2‐tailed)
.002
N
8 8
**. Correlation is significant at the 0.01 level (2‐tailed).

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


29 30
The Point‐Biserial Correlation
SKIP/Optional and the Phi Coefficient

• The Pearson correlation formula can also be


used to measure the relationship between
• Spearman correlation two variables when one or both of the
• Point‐Biserial variables is dichotomous.
correlation • A dichotomous variable is one for which
• Phi‐coefficient there are exactly two categories: for
example, men/women or succeed/fail or
Yes/No

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

31 32
The Point‐Biserial Correlation The Point‐Biserial Correlation
and the Phi Coefficient and the Phi Coefficient
• In situations where one variable
With either one or two dichotomous variables the is dichotomous (nominal or
point-biserial correlation

calculation of the correlation precedes as follows: 0,1 vs numeric


ordinal)and the other consists of
regular numerical scores
1. Assign numerical values to the two categories of
(interval or ratio scale), the
the dichotomous variable(s). Traditionally, one
resulting correlation is called a
category is assigned a value of 0 and the other is phi-coefficient.
point‐biserial correlation.
assigned a value of 1. 0,1 vs 0,1
• When both variables are
2. Use the regular Pearson correlation formula to
dichotomous, the resulting
calculate the correlation.
correlation is called a phi‐
coefficient.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


33 34
Data Structure

SPSS
CORRELATION

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

35 36

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


37 38

Correlations r=0.861 ( strong correlation)


X Y But not significant
X Pearson Correlation 1 .861
Sig. (2‐tailed)
.061
N 5 5
Y Pearson Correlation .861 1
Sig. (2‐tailed)
.061
N 5 5

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

39

www.utm.my innovative ● entrepreneurial ● global


1
Introduction to 2

Linear Regression
• The Pearson correlation measures the
degree to which a set of data points form
a straight line relationship.
• Regression is a statistical procedure that
determines the equation for the straight
line that best fits a specific set of data.
Introduction to Regression

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

Introduction to 3
Introduction to 4

Linear Regression Linear Regression


• Any straight line can be represented by an
equation of the form Y = bX + a, where b
and a are constants.
• The value of b is called the slope constant
and determines the direction and degree to
which the line is tilted.
• The value of a is called the Y‐intercept and
determines the point where the line crosses
the Y‐axis.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


Introduction to 5
Introduction to 6

Linear Regression Linear Regression


The equation for the regression line is

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

Introduction to 7 8

Linear Regression
Example

X Y
2 3
6 11
0 6
4 6
5 7
7 12
5 10
3 9

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


9 10

SPSS

SPSS
Regression

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

11 12

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


13 14
Introduction to Multiple Regression
with Two Predictor Variables

Multiple Regression • In the same way that linear regression


produces an equation that uses values of X
optional to predict values of Y, multiple regression
produces an equation that uses two
different variables (X1 and X2) to predict
values of Y.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

15 16

Introduction to Multiple Regression with


Two Predictor Variables (cont.)
• For two predictor variables, the general form of
the multiple regression equation is:
Ŷ= b1X1 + b2X2 + a

• The ability of the multiple regression equation to


accurately predict the Y values is measured by first
computing the proportion of the Y‐score
variability that is predicted by the regression
equation and the proportion that is not predicted.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


17 18

Example (pg#582)
Person Y(dependent) X1(independent) X2(independent)
A 11 4 10
B 5 5 6
C 7 3 7
D 3 2 4
E 4 1 3
F 12 7 5
G 10 8 8
H 4 2 4
J 8 6 10
J 6 2 3

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

19 20

Example
Person Y(dependent) X1(independent) X2(independent)
A 11 4 10
B 5 5 6
C 7 3 7 SPx1y=52
D 3 2 4
E 4 1 3 SPx2y=47
F 12 7 5
G 10 8 8 SPx1x2=35
H 4 2 4
J 8 6 10
J 6 2 3
My=7 Mx1=4 Mx2=6
SSy=90 SSx1=52 SSx2=64

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


21 22

SPSS
Multiple Regression

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

23 24

SPSS

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


25 26

example
X1 X2 Y
2 4 3
6 3 11
0 4 6
4 5 6
5 6 7
7 4 12
5 6 10
3 5 9

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

27 28

Coefficientsa
ANOVAb
Standardize
Unstandardized  d 
Coefficients Coefficients Sum of  Mean 
Model Squares df Square F Sig.
Model B Std. Error Beta t Sig. 1 Regression
1 (Constant)
37.147 2 18.573 3.458 .114a
5.726 4.123 1.389 .224 Residual
X1 26.853 5 5.371
1.011 .387 .758 2.612 .048
X2 Total
‐.382 .827 ‐.134 ‐.462 .663 64.000 7
a. Dependent Variable: Y
a. Predictors: (Constant), X2, X1

b. Dependent Variable: Y
Y=1.011X1 ‐ 0.382X2 + 5.726

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


29 30

Partial Correlation Partial Correlation (cont.)

• A partial correlation measures the • For example, there probably is no


relationship between two variables (X and underlying relationship between weight and
Y) while eliminating the influence of a third mathematics skill for elementary school
variable (Z). children.
• Partial correlations are used to reveal the • However, both of these variables are
real, underlying relationship between two positively related to age: Older children
variables when researchers suspect that the weigh more and, because they have spent
apparent relation may be distorted by a more years in school, have higher
third variable. mathematics skills.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

31 32

Partial Correlation (cont.)

• As a result, weight and mathematics skill


will show a positive correlation for a sample
of children that includes several different
ages.
• A partial correlation between weight and
mathematics skill, holding age constant,
would eliminate the influence of age and
show the true correlation which is near
zero.

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global


33 34

www.utm.my innovative ● entrepreneurial ● global www.utm.my innovative ● entrepreneurial ● global

35

www.utm.my innovative ● entrepreneurial ● global

Potrebbero piacerti anche