You are on page 1of 44

MTH220

Statistical Methods and Inference


“Statistical thinking will one day be as necessary for efficient citizenship as the ability to read and write”
- H. G. Wells1866 – 1946

Seminar 4, 07 April 2022

MTH220 Lecture Notes SU04 Jan22 1


Recap: statistical inference – one sample
◼ Population mean 𝜇
1. Point estimate

2. Interval estimate

3. Hypothesis testing

MTH220 Lecture Notes SU04 Jan22 2


Recap: statistical inference – one sample
◼ We conduct a 100 × 𝛼% significance level test for the population mean 𝝁
❑ Population distribution is a 𝑵(𝝁, 𝝈𝟐 ) distribution
𝑥ҧ −𝜇0
◼ Population variance 𝜎2 is known: test statistics 𝑍0 =
𝜎/ 𝑛

ҧ 0
𝑥−𝜇
◼ Population variance 𝜎2 is unknown: test statistics 𝑇0 =
𝑆/ 𝑛

❑ Population distribution is a non-normal or unknown distribution, variance 𝜎 2 is


ҧ 0
𝑥−𝜇
unknown. If n>30, we apply Z test, test statistics 𝑍0 =
𝑆/ 𝑛

MTH220 Lecture Notes SU04 Jan22 3


Recap: statistical inference – one sample
◼ Population proportion p
𝑥
• Point estimate : 𝑝Ƹ =
𝑛

𝑝(1−𝑝)
• If n𝑝Ƹ ≥ 5 and n(1 − 𝑝)Ƹ ≥ 5, CLT tells that 𝑝~𝑁(𝑝,
Ƹ ) approximately.
𝑛

𝑝ො 1−𝑝ො ො
𝑝(1− ො
𝑝)
• Interval estimate: 𝑝Ƹ − 𝑧𝜶/𝟐 , 𝑝Ƹ + 𝑧𝛼/2
𝑛 𝑛

𝑝ෝ −𝑝0
• Hypothesis testing: test statistics 𝑍0 =
𝑝0 (1−𝑝0 )/𝑛

MTH220 Lecture Notes SU04 Jan22 4


Recap: type I and type II errors
◼ Type I error:𝜶 = 𝚸(𝒓𝒆𝒋𝒆𝒄𝒕 𝑯𝟎 𝒘𝒉𝒆𝒏 𝑯𝟎 𝒊𝒔 𝒕𝒓𝒖𝒆)
◼ Type II error: 𝚸 𝒇𝒂𝒊𝒍 𝒕𝒐 𝒓𝒆𝒋𝒆𝒄𝒕 𝑯𝟎 𝒘𝒉𝒆𝒏 𝑯𝟎 𝒊𝒔 𝒇𝒂𝒍𝒔𝒆 = 𝟏 − 𝜷
◼ Power of test: 𝚸 𝒓𝒆𝒋𝒆𝒄𝒕 𝑯𝟎 𝒘𝒉𝒆𝒏 𝑯𝟎 𝒊𝒔 𝒇𝒂𝒍𝒔𝒆 = 𝜷

MTH220 Lecture Notes SU04 Jan22 5


Recap: Hypothesis Testing Approaches
◼ Critical region
◼ Confidence interval
◼ P-value

MTH220 Lecture Notes SU04 Jan22 6


Recap: Hypothesis Testing Approaches
◼ Critical region
◼ Confidence interval
◼ P-value

MTH220 Lecture Notes SU04 Jan22 7


Seminar 4
◼ Hypothesis Testing (Two sample)

❑ testing on the difference of two population means

❑ Testing on the difference of two population proportions

MTH220 Lecture Notes SU04 Jan22 8


SU 04
Chapter 1
Two sample - Introduction

MTH220 Lecture Notes SU04 Jan22 9


1.1 Two sample problem
Example:
1. Do brand A tablets have longer battery life than brand B tablets?
2. Is a new drug effective in reducing high blood pressure?

Remark: some samples are taken from two different populations, while some
samples are taken from the same population, twice. It is important to
distinguish between independent and dependent samples before
formulating any hypotheses.

MTH220 Lecture Notes SU04 Jan22 10


1.1 Independent samples vs Dependent samples
◼ Two samples are independent if the values from one sample are
not related to or paired to the values from another sample.
◼ Two samples are dependent if each value from one sample is
paired to or matched with another value from another sample.
◼ Dependent samples are also called paired samples.

MTH220 Lecture Notes SU04 Jan22 11


1.1 Independent samples vs Dependent samples
Example
1. A consumer compares the battery life of brand A and brand B tablets.

2. A dietitian enrolls 30 volunteers in a new diet program. All volunteers will take the
same diet for a week and their weights are measured before and after the program.

3. A researcher randomly assigns 30 patients with hypertension to either control group


or treatment group. Patients in the treatment group take a new drug everyday while
those in control group take a placebo. The blood pressure of patients in both groups
are measured and compared after one month.

4. Alice compares the online prices and retail prices of 30 textbooks.

MTH220 Lecture Notes SU04 Jan22 12


SU 04
Chapter 2
Statistical Inference for the Difference of Two
Population Means: Independent Samples

MTH220 Lecture Notes SU04 Jan22 13


2.1 Testing population means of 2 populations: Independent
samples
◼ Suppose that we have two independent samples
Sample 1: 𝑋11 , 𝑋12 , ⋯ , 𝑋1𝑛1 ~𝑁(𝜇1 , 𝜎12 )
Sample 2: 𝑋21 , 𝑋22 , ⋯ , 𝑋2𝑛2 ~𝑁(𝜇2 , 𝜎22 )
❑ Goal: perform hypothesis test at significance level 𝛼 for the difference of
population means 𝜇1 − 𝜇2

MTH220 Lecture Notes SU04 Jan22 14


2.1 Testing population means of 2 populations:
Independent samples
◼ Independent samples:
2
◼ 𝑋11 , 𝑋12 , ⋯ , 𝑋1𝑛 ~𝑁(𝜇1 , 𝜎1 ) and
1

◼ 𝑋21 , 𝑋22 , ⋯ , 𝑋2𝑛2 ~𝑁(𝜇2 , 𝜎22 )


❑ Point estimators
sample mean for sample 2
sample mean for sample 1 1 𝑛2
1 𝑛1 𝑋2 = σ 𝑗=1 𝑋2𝑗
𝑋1 = σ 𝑗=1 𝑋1𝑗
𝑛2
𝑛1
sample variance for sample 2
sample variance for sample 1 𝑛2
1 𝑛1 2 1 2
2
𝑆1 = σ𝑗=1 𝑋1𝑗 − 𝑋1 𝑆22 = ෍ 𝑋2𝑗 − 𝑋2
𝑛1 −1 𝑛2 − 1
𝑗=1

MTH220 Lecture Notes SU04 Jan22 15


2.1 Testing population means of 2 populations: Independent
samples; known variance
◼ Independent samples 𝑋11 , 𝑋12 , ⋯ , 𝑋1𝑛1 ~𝑁(𝜇1 , 𝜎12 ) and 𝑋21 , 𝑋22 , ⋯ , 𝑋2𝑛2 ~𝑁(𝜇2 , 𝜎22 )
❑ Suppose we know the values of 𝜎12 and 𝜎22
❑ Goal: perform hypothesis test at significance level 𝛼 for the difference of population
means 𝜇1 − 𝜇2
◼ We conduct a 100 × 𝛼% significance level test

𝐻0 : 𝜇1 − 𝜇2 = Δ0 𝐻0 : 𝜇1 − 𝜇2 = Δ0 𝐻0 : 𝜇1 − 𝜇2 = Δ0
Hypothesis test
𝐻1 : 𝜇1 − 𝜇2 ≠ Δ0 𝐻1 : 𝜇1 − 𝜇2 < Δ0 𝐻1 : 𝜇1 − 𝜇2 > Δ0
Test statistic ?
Critical region ? ? ?

MTH220 Lecture Notes SU04 Jan22 16


2.1 Testing population means of 2 populations: Independent
samples; known variance
◼ Independent samples 𝑋11 , 𝑋12 , ⋯ , 𝑋1𝑛1 ~𝑁(𝜇1 , 𝜎12 ) and 𝑋21 , 𝑋22 , ⋯ , 𝑋2𝑛2 ~𝑁(𝜇2 , 𝜎22 )
❑ Suppose we know the values of 𝜎12 and 𝜎22
❑ The distribution of the difference in sample means
𝜎12 𝜎22
𝑋1 − 𝑋2 ~𝑁 𝜇1 − 𝜇2 , +
𝑛1 𝑛2
❑ Under 𝐻0 , the test statistic is

𝑋1 − 𝑋2 − Δ0
𝑍= ~𝑁 0,1
𝜎12 𝜎22
+
𝑛1 𝑛2

MTH220 Lecture Notes SU04 Jan22 17


2.1 Testing population means of 2 populations: Independent
samples; known variance
◼ Independent samples 𝑋11 , 𝑋12 , ⋯ , 𝑋1𝑛1 ~𝑁(𝜇1 , 𝜎12 ) and 𝑋21 , 𝑋22 , ⋯ , 𝑋2𝑛2 ~𝑁(𝜇2 , 𝜎22 )
❑ Suppose we know the values of 𝜎12 and 𝜎22
◼ We conduct a 100 × 𝛼% significance level test

𝐻0 : 𝜇1 − 𝜇2 = Δ0 𝐻0 : 𝜇1 − 𝜇2 = Δ0 𝐻0 : 𝜇1 − 𝜇2 = Δ0
Hypothesis test
𝐻1 : 𝜇1 − 𝜇2 ≠ Δ0 𝐻1 : 𝜇1 − 𝜇2 < Δ0 𝐻1 : 𝜇1 − 𝜇2 > Δ0
𝑋1 − 𝑋2 − Δ0
𝑍0 =
Test statistic 𝜎12 𝜎22
+
𝑛1 𝑛2

𝑧 > 𝑧𝛼/2 or
Critical region 𝑧 < −𝑧𝛼 𝑧 > 𝑧𝛼
𝑧 < −𝑧𝛼/2

MTH220 Lecture Notes SU04 Jan22 18


2.1 CI for difference in means of 2 populations: Independent
samples; known variance
◼ Independent samples 𝑋11 , 𝑋12 , ⋯ , 𝑋1𝑛1 ~𝑁(𝜇1 , 𝜎12 ) and 𝑋21 , 𝑋22 , ⋯ , 𝑋2𝑛2 ~𝑁(𝜇2 , 𝜎22 )
❑ Suppose we know the values of 𝜎12 and 𝜎22
❑ The distribution of the difference in sample means
𝜎12 𝜎22
𝑋1 − 𝑋2 ~𝑁 𝜇1 − 𝜇2 , +
𝑛1 𝑛2
◼ A 100 × 1 − 𝛼 % confidence interval for 𝜇1 − 𝜇2

𝑝𝑜𝑖𝑛𝑡 𝑒𝑠𝑡𝑖𝑚𝑎𝑡𝑜𝑟 ± 𝑞𝑢𝑎𝑛𝑡𝑖𝑙𝑒 × 𝑠𝑡𝑎𝑛𝑑𝑎𝑟𝑑 𝑒𝑟𝑟𝑜𝑟

MTH220 Lecture Notes SU04 Jan22 19


2.1 Testing population means of 2 populations: Independent
samples; known variance: example

populations are normally distributed and the population variances are known, given by 𝜎12 = 1 and 𝜎22 = 1.

MTH220 Lecture Notes SU04 Jan22 20


2.1 Testing population means of 2 populations: Independent
samples; known variance: example
Solution:

MTH220 Lecture Notes SU04 Jan22 21


2.2 Testing population means of 2 populations: Independent
samples; unknown variance
◼ Independent samples 𝑋11 , 𝑋12 , ⋯ , 𝑋1𝑛1 ~𝑁(𝜇1 , 𝜎12 ) and 𝑋21 , 𝑋22 , ⋯ , 𝑋2𝑛2 ~𝑁(𝜇2 , 𝜎22 )
❑ Suppose the values of 𝜎12 and 𝜎22 are unknown
❑ We know 𝜎12 = 𝜎22
❑ The distribution of the difference in sample means
𝜎12 𝜎22
𝑋1 − 𝑋2 ~𝑁 𝜇1 − 𝜇2 , +
𝑛1 𝑛2
❑ We estimate the common variance of the two populations by using the pooled sample
variance
2 2
𝑛1 − 1 𝑠1 + 𝑛 2 − 1 𝑠2
𝑠𝑝2 =
𝑛1 − 𝑛2 − 2

MTH220 Lecture Notes SU04 Jan22 22


2.2 Testing population means of 2 populations: Independent
samples; unknown variance
◼ Independent samples 𝑋11 , 𝑋12 , ⋯ , 𝑋1𝑛1 ~𝑁(𝜇1 , 𝜎12 ) and 𝑋21 , 𝑋22 , ⋯ , 𝑋2𝑛2 ~𝑁(𝜇2 , 𝜎22 )
❑ Suppose the values of 𝜎12 and 𝜎22 are unknown
❑ We know 𝜎12 = 𝜎22
❑ Thus
𝑋1 − 𝑋2 − 𝜇1 − 𝜇2
~𝑡𝑛1 −𝑛2 −2
1 1
𝑠𝑝 +
𝑛1 𝑛2
❑ Under 𝐻0 , the test statistic is
𝑋1 − 𝑋2 − Δ0
𝑇=
1 1
𝑠𝑝 +
𝑛1 𝑛2
MTH220 Lecture Notes SU04 Jan22 23
2.2 Testing population means of 2 populations: Independent
samples; unknown variance
◼ Independent samples 𝑋11 , 𝑋12 , ⋯ , 𝑋1𝑛1 ~𝑁(𝜇1 , 𝜎12 ) and 𝑋21 , 𝑋22 , ⋯ , 𝑋2𝑛2 ~𝑁(𝜇2 , 𝜎22 )
❑ Suppose the values of 𝜎12 and 𝜎22 are unknown
❑ We know 𝜎12 = 𝜎22
◼ We conduct a 100 × 𝛼% significance level test

𝐻0 : 𝜇1 − 𝜇2 = Δ0 𝐻0 : 𝜇1 − 𝜇2 = Δ0 𝐻0 : 𝜇1 − 𝜇2 = Δ0
Hypothesis test
𝐻1 : 𝜇1 − 𝜇2 ≠ Δ0 𝐻1 : 𝜇1 − 𝜇2 < Δ0 𝐻1 : 𝜇1 − 𝜇2 > Δ0
𝑋1 − 𝑋2 − Δ0
𝑇=
Test statistic 1 1
𝑠𝑝 +
𝑛1 𝑛2
𝑡 > 𝑡𝑛1−𝑛2−2,𝛼Τ2 or
Critical region t < −𝑡𝑛1−𝑛2−2,𝛼 𝑡 > 𝑡𝑛1−𝑛2−2,𝛼
t < −𝑡𝑛1−𝑛2−2,𝛼Τ2

MTH220 Lecture Notes SU04 Jan22 24


2.2 CI for difference in means of 2 populations: Independent
samples; unknown variance
◼ Independent samples 𝑋11 , 𝑋12 , ⋯ , 𝑋1𝑛1 ~𝑁(𝜇1 , 𝜎12 ) and 𝑋21 , 𝑋22 , ⋯ , 𝑋2𝑛2 ~𝑁(𝜇2 , 𝜎22 )
❑ Suppose the values of 𝜎12 and 𝜎22 are unknown
2 2
❑ We know 𝜎1 = 𝜎2

❑ The distribution of the difference in sample means


𝑋1 − 𝑋2 − 𝜇1 − 𝜇2
~𝑡𝑛1 −𝑛2 −2
1 1
𝑠𝑝 +
𝑛1 𝑛2
A 100 × 1 − 𝛼 % confidence interval for 𝜇1 − 𝜇2

𝑝𝑜𝑖𝑛𝑡 𝑒𝑠𝑡𝑖𝑚𝑎𝑡𝑜𝑟 ± 𝑞𝑢𝑎𝑛𝑡𝑖𝑙𝑒 × 𝑠𝑡𝑎𝑛𝑑𝑎𝑟𝑑 𝑒𝑟𝑟𝑜𝑟

MTH220 Lecture Notes SU04 Jan22 25


2.2 Testing population means of 2 populations: Independent
samples; unknown variance: example
A teacher has given the 17 children in his class a reading test. The results for both girls and
boys are shown in the following table. Test the evidence provided by the data that girls tend
to be better readers than boys. at significance level 5%.

MTH220 Lecture Notes SU04 Jan22 26


2.2 Testing population means of 2 populations: Independent
samples; unknown variance: example
Solution

MTH220 Lecture Notes SU04 Jan22 27


2.2 Testing population means of 2 populations: Independent
samples; unknown variance: example
Solution

MTH220 Lecture Notes SU04 Jan22 28


SU 04
Chapter 3
Statistical Inference for the Difference of Two
Population Proportions: Independent Samples

MTH220 Lecture Notes SU04 Jan22 29


3.1 Testing population proportions of 2 populations: Independent
samples
◼ Two populations:
◼ 𝑝1 be the population proportion of “successes” in population 1

◼ 𝑝2 be the population proportion of “successes” in population 2

◼ Define

𝑌1 = number of “successes” in Sample 1 (out of 𝑛1 individuals) ∼ 𝑩(𝒏𝟏 , 𝒑𝟏 )


𝑌2 = number of “successes” in Sample 2 (out of 𝑛2 individuals) ∼ 𝑩(𝒏𝟐 , 𝒑𝟐 )
◼ The point estimators for 𝑝1 and 𝑝2 are the sample proportions,
𝑌1 𝑌2
𝑝
ෞ1 = ,𝑝
ෞ2 =
𝑛1 𝑛2
◼ Goal: perform hypothesis test at significance level 𝜶 for the difference of two population
proportions 𝑝1 − 𝑝2 .

MTH220 Lecture Notes SU04 Jan22 30


3.1 Testing population proportions of 2 populations: Independent
samples
◼ When the sample sizes 𝑛1 and 𝑛2 are large enough, the difference in sample proportions
𝑝
ෞ1 − 𝑝 ෞ2 − (𝑝1 − 𝑝2 )
𝑍= ~𝑁 0,1
𝑝1 (1 − 𝑝1 ) 𝑝2 (1 − 𝑝2 )
+
𝑛1 𝑛2
approximately.
Remark:
1. The two samples are independent
2. the sample sizes 𝑛1 and 𝑛2 are at least 30
3. ෞ𝟏 ≥ 𝟓, 𝒏𝟏 (𝟏 − 𝒑
We require 𝐧𝟏 𝒑 ෞ𝟏 ) ≥ 𝟓 and 𝐧𝟐 𝒑
ෞ𝟐 ≥ 𝟓, 𝒏𝟐 (𝟏 − 𝒑
ෞ𝟐 ) ≥ 𝟓

MTH220 Lecture Notes SU04 Jan22 31


3.1 Testing population proportions of 2 populations: Independent
samples
◼ We conduct a 100 × 𝛼% significance level test

𝐻0 : 𝑝1 = 𝑝2 𝐻0 : 𝑝1 = 𝑝2 𝐻0 : 𝑝1 = 𝑝2
Hypothesis test
𝐻1 : 𝑝1 ≠ 𝑝2 𝐻1 : 𝑝1 < 𝑝2 𝐻1 : 𝑝1 > 𝑝2
ෞ1 −ෞ
𝑝 𝑝2
𝑍= 1 1

𝑝(1− ො
𝑝) +
𝑛1 𝑛2
Test statistic
𝑌1 + 𝑌2
𝑝Ƹ =
𝑛1 + 𝑛2
𝑧 > 𝑧𝛼Τ2 or
Critical region z < −𝑧𝛼 𝑧 > 𝑧𝛼
z < −𝑧𝛼Τ2

MTH220 Lecture Notes SU04 Jan22 32


3.1 Testing population proportions of 2 populations: Independent
samples: example
A programmable lighting control system is being designed. The purpose of the system is to
reduce electricity consumption costs in buildings. The system eventually will entail the use
of a large number of transceivers (a device comprised of both a transmitter and a receiver).
Two types of transceivers are being considered. In life testing, 200 transceivers (randomly
selected) were tested for each type.
Transceiver 1: 20 failures were observed (out of 200)
Transceiver 2: 14 failures were observed (out of 200)
Define 𝑝1 (𝑝2 ) to be the population proportion of Transceiver 1 (Transceiver 2) failures.
Write a 95 percent confidence interval for 𝑝1 − 𝑝2 . Is there a Signiant difference between
the failure rates 𝑝1 and 𝑝2 ?

MTH220 Lecture Notes SU04 Jan22 33


3.1 Testing population proportions of 2 populations: Independent
samples: example
Solution

MTH220 Lecture Notes SU04 Jan22 34


SU 04
Chapter 4
Statistical Inference for the Difference of Two
Population Means: Dependent Samples

MTH220 Lecture Notes SU04 Jan22 35


4.1 Testing population means of 2 populations: dependent samples
◼ Dependent samples
𝑋1 , 𝑋2 , ⋯ , 𝑋𝑛 (e.g. observations before the treatment)
𝑌1 , 𝑌2 , ⋯ , 𝑌𝑛 (e.g. observations after the treatment)
❑ We define the difference 𝐷𝑖 = 𝑋𝑖 − 𝑌𝑖
2 2
❑ Assume that 𝐷𝑖 are independent observations from a 𝑁(𝜇, 𝜎 ) distribution, where 𝜎 is
unknown
❑ Goal: perform hypothesis test at significance level 𝛼 for the difference 𝐷𝑖 .

❑ Remark: Basically, you take the difference, then perform a T-test on the differences.

MTH220 Lecture Notes SU04 Jan22 36


4.1 Testing population means of 2 populations: dependent samples
◼ Dependent samples 𝑋1 , 𝑋2 , ⋯ , 𝑋𝑛 and 𝑌1 , 𝑌2 , ⋯ , 𝑌𝑛
❑ We define the difference 𝐷𝑖 = 𝑋𝑖 − 𝑌𝑖 for 𝑖 = 1, … , 𝑛
❑ Assume that 𝐷𝑖 are independent observations from a 𝑁(𝜇, 𝜎 2 ) distribution, where 𝜎 2 is
unknown
◼ Data difference 𝐷1 , 𝐷2 , ⋯ , 𝐷𝑛
◼ We conduct a 100 × 𝛼% significance level test

𝐻0 : 𝜇𝑫 = Δ0 𝐻0 : 𝜇𝑫 = Δ0 𝐻0 : 𝜇𝑫 = Δ0
Hypothesis test
𝐻1 : 𝜇𝑫 ≠ Δ0 𝐻1 : 𝜇𝑫 < Δ0 𝐻1 : 𝜇𝑫 > Δ0
Test statistic ?

Critical region ? ? ?

MTH220 Lecture Notes SU04 Jan22 37


4.1 Testing population means of 2 populations: dependent
samples
◼ Dependent samples 𝑋1 , 𝑋2 , ⋯ , 𝑋𝑛 and 𝑌1 , 𝑌2 , ⋯ , 𝑌𝑛
❑ We define the difference 𝐷𝑖 = 𝑋𝑖 − 𝑌𝑖 for 𝑖 = 1, … , 𝑛
❑ Assume that 𝐷𝑖 are independent observations from a 𝑁(𝜇𝐷 , 𝜎𝐷2 ) distribution, where 𝜎𝐷2 is
unknown.
◼ Under 𝐻0 , the test statistic is
𝑋ത − 𝜇𝐷
𝑇= ~𝑡𝑛−1
𝑆𝐷 / 𝑛

MTH220 Lecture Notes SU04 Jan22 38


4.1 Testing population means of 2 populations: dependent
samples
◼ Dependent samples 𝑋1 , 𝑋2 , ⋯ , 𝑋𝑛 and 𝑌1 , 𝑌2 , ⋯ , 𝑌𝑛
❑ We define the difference 𝐷𝑖 = 𝑋𝑖 − 𝑌𝑖 for 𝑖 = 1, … , 𝑛
❑ Assume that 𝐷𝑖 are independent observations from a 𝑁(𝜇, 𝜎 2 ) distribution, where 𝜎 2 is
unknown
◼ We conduct a 100 × 𝛼% significance level test
𝐻0 : 𝜇𝑫 = Δ0 𝐻0 : 𝜇𝑫 = Δ0 𝐻0 : 𝜇𝑫 = Δ0
Hypothesis test
𝐻1 : 𝜇𝑫 ≠ Δ0 𝐻1 : 𝜇𝑫 < Δ0 𝐻1 : 𝜇𝑫 > Δ0
𝑋ത − 𝜇𝐷
Test statistic 𝑇= ~𝑡𝑛−1
𝑆𝐷 / 𝑛
𝑡 > 𝑡𝑛−1,𝛼Τ2 or
Critical region t < −𝑡𝑛−1,𝛼 𝑡 > 𝑡𝑛−1,𝛼
t < −𝑡𝑛−1,𝛼Τ2

MTH220 Lecture Notes SU04 Jan22 39


4.1 CI for difference in means of 2 populations: dependent
samples
◼ Dependent samples 𝑋1 , 𝑋2 , ⋯ , 𝑋𝑛 and 𝑌1 , 𝑌2 , ⋯ , 𝑌𝑛
❑ We define the difference 𝐷𝑖 = 𝑋𝑖 − 𝑌𝑖 for 𝑖 = 1, … , 𝑛
2 2
❑ Assume that 𝐷𝑖 are independent observations from a 𝑁(𝜇, 𝜎 ) distribution, where 𝜎 is
unknown
❑ We have
𝑋ത − 𝜇𝐷
𝑇= ~𝑡𝑛−1
𝑆𝐷 / 𝑛
A 100 × 1 − 𝛼 % confidence interval for 𝜇1 − 𝜇2

𝑝𝑜𝑖𝑛𝑡 𝑒𝑠𝑡𝑖𝑚𝑎𝑡𝑜𝑟 ± 𝑞𝑢𝑎𝑛𝑡𝑖𝑙𝑒 × 𝑠𝑡𝑎𝑛𝑑𝑎𝑟𝑑 𝑒𝑟𝑟𝑜𝑟

MTH220 Lecture Notes SU04 Jan22 40


4.1 Testing population means of 2 populations: dependent
samples: example

at significance level 5%?


MTH220 Lecture Notes SU04 Jan22 41
4.1 Testing population means of 2 populations: dependent samples
Solution

MTH220 Lecture Notes SU04 Jan22 42


4.1 Testing population means of 2 populations: dependent samples
Solution

MTH220 Lecture Notes SU04 Jan22 43


Reading Material
◼ Study unit 4 of the Study Guide
◼ Chapter 8 of the e-textbook

MTH220 Lecture Notes SU04 Jan22 44

You might also like