Ignacio Cascos Fernández
Department of Statistics
Universidad Carlos III de Madrid
Statistical Inference
Statistics — 2014–2015
1 Estimation
A random sample of size n is formed by n independent random variables
X1 , X2 , . . . , Xn sampled from the same population. That is, X1 , X2 , . . . , Xn
follow the distribution of X.
1.1 Statistics (estimators)
Our aim is to obtain information about the population parameters (mean,
variance, proportion,. . . ) when only a sample is available.
A statistic is any transformation (function) of the observations of a ran-
dom sample. Consequently, it is a random variable, f (X1 , X2 , . . . , Xn ) .
An estimator of a parameter θ is any statistic θ̂ = f (X1 , X2 , . . . , Xn ) that
provides us with approximate value of θ.
The value that an estimator assumes in a real sample (when the random
variables are substituted by real numbers) is called estimation.
1.2 Properties of estimators
Unbiased estimator. An estimator of a parameter θ is unbiased if is ex-
pected value is θ, that is, θ̂ is unbiased if E[θ̂] = θ.
The distance of the expectation of the estimator to the true value of the
parameter E[θ̂] − θ is called bias,
bias[θ̂] = E[θ̂] − θ .
1
Efficiency. From several unbiased estimators of a parameter, we would
choose the one with a smaller variance. The efficiency of an estimator is the
inverse to its variance,
1
Eff[θ̂] = .
var[θ̂]
We can compare two unbiased estimators by means of their relative effi-
ciency, which is given by
Eff[θ̂2 ] var[θ̂1 ]
RE[θ̂2 ; θ̂1 ] = = .
Eff[θ̂1 ] var[θ̂2 ]
The standard error of an estimator is its standard deviation,
q
σθ̂ = var[θ̂] .
When the standard error depends of the true value of parameter θ, we can
substitute θ by an estimation in order to obtain the estimated standard error
σ̂θ̂ .
Mean Square Error. We can compare biased and unbiased estimators by
means of the Mean Square Error given by
MSE[θ̂] = E[(θ̂ − θ)2 ] = var[θ̂] + bias[θ̂]2 .
Consistency. An estimator is consistent if the probability of it being ar-
bitrarily close to the true value of the parameter converges to one as the
sample size tends to infinity.
It is the minimal requirement for a good estimator.
1.3 Sampling distributions
1.4 Distribution of the sample mean
Given a random variable X with mean µ and known standard deviation
σ, consider X1 , X2 , . . . , Xn a random sample from X of size n. That is,
X1 , X2 , . . . , Xn are n independent random variables with the distribution of
X. The sample mean is given by
n
1X
X= Xi
n i=1
2
which is obviously a random variable.
The sample mean is an unbiased estimator of the population mean µ,
that is, E[X] = µ and its variance is var[X] = σ 2 /n .
If X is normally distributed, then X also follows a normal distribution.
√ Limit Theorem (if n ≥ 30) the distribution of
Further, after the Central
X is approximately N(µ, σ/ n).
Distribution of the sample proportion. The sample proportion is a
particular case of sample mean. Let p denote the population proportion
of individuals with a certain characteristic. We will take an individual at
random from the population and consider the random variable X that assume
value 1 if the individual has the characteristic and 0 otherwise. Obviously
X ∼ B(1, p).
Let us now take a random sample of X of size n, X1 , X2 , . . . , Xn , then
n
1X
X= Xi = p̂
n i=1
represents the quotient of the number of individuals from the sample with
the characteristic divided by the sample size, that is, the sample proportion.
Finally, if n ≥ 30, after
p the Central Limit Theorem, the distribution of p̂
is approximately N(p, p(1 − p)/n ).
1.5 Distribution of the sample variance
Consider a random sample X1 , X2 , . . . , Xn of a random variable X (defin-
ing the population distribution) with mean µ and variance σ. The sample
variance given by
n
2 1 X
S = (Xi − X)2
n − 1 i=1
is an unbiased estimator of the population variance σ 2 , that is E[S 2 ].
1.6 Sampling distributions for normal populations
Distribution of the sample variance (normal population). Let X ∼
N(µ, σ) and X1 , X2 , . . . , Xn be a random sample of X of size n, the distribu-
3
tion of the sample variance S 2 satisfies
(n − 1)S 2
∼ χ2n−1
σ2
where χ2n−1 stands for the chi-square distribution with n − 1 degrees of free-
dom.
Distribution of the sample mean with unknown variance (normal
population). Let X ∼ N(µ, σ) and X1 , X2 , . . . , Xn be a random sample
of X of size n, if σ is unknown, we can estimate the variance through the
sample variance, and the distribution of the sample mean X satisfies
X −µ
p ∼ tn−1
S 2 /n
where tn−1 stands for the t distribution with n − 1 degrees of freedom.
Distribution of the quotient of sample variances (normal popula-
tions). Let X ∼ N(µX , σX ) and X1 , X2 , . . . , Xn be a random sample of X
of size n, and let Y ∼ N(µY , σY ) and Y1 , Y2 , . . . , Yn be a random sample of
Y of size m. The ratio of their sample variances satisfies
2 2
SX /σX
∼ Fn−1,m−1
SY2 /σY2
where Fn−1,m−1 stands for the F distribution with n − 1 and m − 1 degrees
of freedom.
Addendum: Common sampling distributions
Pearson’s Chi-square distribution, χ2n . Given n independent standard
normal random variables X1 , X2 , . . . , Xn , the random variable
Y = X12 + X22 + . . . + Xn2
follows a Chi-square distribution with n degrees of freedom, denoted by Y ∼
χ2n .
A Chi-square random variable only assumes positive values and its pa-
rameters are:
E[Y ] = n ; var[Y ] = 2n.
4
Student’s t distribution, tn . Given X and Y two independent random
variables such that X follows a standard normal distribution and Y follows
a Chi-square distribution with n degrees of freedom, the random variable
X
Z=p
Y /n
follows a t distribution with n degrees of freedom, denoted by Z ∼ tn .
A random variable with distribution t can assume any real value.
n
E[X] = 0 ; var[X] = if n ≥ 3.
n−2
For large enough values of n, the tn distribution is very similar to the standard
normal.
Fisher’s F distribution, Fn1 ,n2 . Given X and Y two independent random
variables such that X follows a Chi-square distribution with n1 degrees of
freedom and Y follows a Chi-square distribution with n2 degrees of freedom,
the random variable
X/n1
Z=
Y /n2
follows a F distribution with n1 and n2 degrees of freedom, denoted by Z ∼
Fn1 ,n2 . A random variable with distribution F can only assume positive
values.
2 Confidence Intervals
For a fixed probability 1−α which is referred to as confidence level, a given pa-
rameter θ of a probability distribution, and a random sample X1 , X2 , . . . , Xn ,
it is possible to build an interval based on the sample which contains the true
value of θ with probability 1 − α.
P (θ̂1 (X1 , X2 , . . . , Xn ) ≤ θ ≤ θ̂2 (X1 , X2 , . . . , Xn )) = 1 − α .
If we consider now a sample of observations (real numbers) x1 , x2 , . . . , xn and
substitute the statistics θ̂1 and θ̂2 by the value that they adopt for the sample
of real numbers, we obtain a confidence interval on θ with confidence level
1 − α as
[θ̂1 (x1 , x2 , . . . , xn ) , θ̂2 (x1 , x2 , . . . , xn )] .
5
The way a confidence interval should be interpreted is the following: If we
consider a large number of independent samples from the same population
and we build a confidence interval on θ for each of them following the same
procedure, approximately (1 − α)% of all such intervals will contain the true
value of θ.
The greater the confidence level is, the wider the confidence interval will
be. The aim when constructing a confidence interval is to obtain the narrow-
est interval with the prescribed confidence level. The length of the confidence
interval will also depend on the variance of the chosen estimator of the pa-
rameter and, consequently, on the sample size. For a prescribed confidence
level, the larger the sample is, the narrower the confidence interval will be.
2.1 Particular instances of Confidence Intervals
You can find below some specific confidence intervals with confidence level
1−α (they are alternatively referred to as (1−α)×100% confidence intervals).
The notation we will use in the following is: Z ∼ N(0, 1), T ∼ tn , X ∼ χn ,
F ∼ Fn1 ,n2 for any α ∈ (0, 1), zα , tn,α , χn,α , fn1 ,n2 ,α are used for the (1 − α)-
quantiles of the aforementioned distributions (the ones that correspond to an
upper tail probability equal to α) P (Z ≥ zα ) = α, P (T ≥ tn,α ) = α, P (X ≥
χn,α ) = α, and P (F ≥ fn1 ,n2 ,α ) = α . Furthermore fn2 ,n1 ,1−α = 1/fn1 ,n2 ,α .
Confidence Interval on the mean of a normal population (or large
sample) with known variance. Let X ∼ N(µ, σ) with σ known, consider
X1 , X2 , . . . , Xn a random sample of size n.
A confidence interval on µ with confidence level 1 − α is built as
σ σ
x − zα/2 √ , x + zα/2 √ ,
n n
where x is the sample mean. The formula also applies when the population
is not normal, as long as the sample size (n) is large, and σ known.
Confidence Interval on a proportion. Consider a population with a
proportion p of individuals with a given characteristic, and a sample propor-
tion p̂ obtained from a sample with at least n ≥ 30 observations.
A confidence interval on p with confidence level 1 − α is built as
r r
p̂(1 − p̂) p̂(1 − p̂)
p̂ − zα/2 , p̂ + zα/2 .
n n
6
Confidence Interval on the mean of a normal population with un-
known variance. Let X ∼ N(µ, σ) with σ unknown, consider X1 , . . . , Xn
a random sample of size n.
A confidence interval on µ with confidence level 1 − α is built as
s s
x − tn−1,α/2 √ , x + tn−1,α/2 √ ,
n n
where x is the sample mean and s2 the sample variance.
Confidence Interval on the variance of a normal population. Let
X ∼ N(µ, σ), consider X1 , X2 , . . . , Xn a random sample of size n.
A confidence interval on σ with confidence level 1 − α is built as
(n − 1)s2 (n − 1)s2
, ,
χn−1,α/2 χn−1,1−α/2
where s2 is the sample variance.
Confidence Interval on a parameter based on its Maximum Likeli-
hood Estimator. Let θ be any parameter, and θ̂M L its maximum likeli-
hood estimator
A confidence interval on θ with confidence level 1 − α is built as
h i
θ̂M L − zα/2 σ̂θ̂M L , θ̂M L + zα/2 σ̂θ̂M L ,
where σ̂θ̂M L is the estimated standard error of θ̂M L .
Confidence Interval on the difference in proportions of two popu-
lations. Consider two populations, the first of them has a proportion p1 of
individuals with a given characteristic, while the second has a proportion p2
of individuals with the characteristic. Take two independent random sam-
ples, one from each population, with respective sample proportions p̂1 and
p̂2 and sample sizes n1 , n2 ≥ 30.
A confidence interval on p1 − p2 with confidence level 1 − α is built as
s
p̂1 (1 − p̂1 ) p̂2 (1 − p̂2 )
(p̂1 − p̂2 ) − zα/2 + ,
n1 n2
s
p̂1 (1 − p̂1 ) p̂2 (1 − p̂2 )
(p̂1 − p̂2 ) + zα/2 + ,
n1 n2
7
Confidence Interval on the difference in means of two normal pop-
ulations with known variances. Let X ∼ N(µ1 , σ1 ) and Y ∼ N(µ2 , σ2 ),
consider X1 , X2 , . . . , Xn1 a random sample of X of size n1 , and Y1 , Y2 , . . . , Yn2
a random sample of Y of size n2 independent of the first sample. The stan-
dard deviations σ1 and σ2 are known.
A confidence interval on µ1 − µ2 with confidence level 1 − α is built as
s s
σ12 σ22 σ12 σ22
(x − y) − zα/2 + , (x − y) + zα/2 + ,
n1 n2 n1 n2
where x is the sample mean of the first sample and y the sample mean of
the second sample. The formula also applies for non-normal populations as
long as both sample sizes are large. It also applies for unknown population
variances after substituting the population variances by the sample variances
as long as both sample sizes are large.
Confidence interval on the difference in means of two normal pop-
ulations with unknown, but equal variances. Let X ∼ N(µ1 , σ) and
Y ∼ N(µ2 , σ), consider X1 , X2 , . . . , Xn1 a random sample of X of size n1 ,
and Y1 , Y2 , . . . , Yn2 a random sample of Y of size n2 independent of the first
sample. The common standard deviation σ is unknown.
A confidence interval on µ1 − µ2 with confidence level 1 − α is built as
s r
(n1 − 1)s21 + (n2 − 1)s22 1
1
(x − y) − tn1 +n2 −2,1−α/2 + ,
n1 + n2 − 2 n1 n2
s r
(n1 − 1)s21 + (n2 − 1)s22 1
1
(x − y) + tn1 +n2 ,1−α/2 + ,
n1 + n2 − 2 n1 n2
where x and s21 are the sample mean and variance of the first sample, y
and s22 are the sample mean and variance of the second sample, and Sp2 =
((n1 − 1)S12 + (n2 − 1)S22 ) /(n1 +n2 −2) is an estimator of σ 2 known as pooled
variance.
Confidence Interval on the variance ratio of two normal popula-
tions. Let X ∼ N(µ1 , σ1 ) and Y ∼ N(µ2 , σ2 ), consider X1 , X2 , . . . , Xn1 a
random sample of X of size n1 , and Y1 , Y2 , . . . , Yn2 a random sample of Y of
size n2 independent of the first sample.
8
A confidence interval on σ12 /σ22 with confidence level 1 − α is built as
2
s21
s1
fn −1,n1 −1,1−α/2 , 2 fn2 −1,n1 −1,α/2 ,
s22 2 s2
where s21 is the sample variance of the first sample, and s22 the sample variance
of the second sample.
Confidence Interval on the difference in means of two normal pop-
ulations, paired data. Let (X, Y ) be a bivariate random vector with
E[X] = µ1 , E[Y ] = µ2 , and such that X − Y can be assumed to be nor-
mally distributed. Consider a random sample (X1 , Y1 ), . . . , (Xn , Yn ).
A confidence interval on µ1 − µ2 with confidence level 1 − α is built as
sd sd
d − tn−1,α/2 √ , d + tn−1,α/2 √ ,
n n
where d is the sample mean difference of the sample x1 − y1 , . . . , xn − yn , and
s2d its sample variance.
3 Hypothesis testing
A statistical hypothesis is a conjecture (statement) about a population distri-
bution. Such statements are commonly about the parameters (e.g. mean or
standard deviation) of the population. Statistical inference consists on the
usage of sample information to confirm (or discard) some given statistical
hypothesis.
The null hypothesis H0 is the conjecture that we want to confirm (or
discard), while the alternative hypothesis H1 occurs whenever H0 does not.
A statistical test formally consists on the confrontation of the null versus
alternative hypothesis. In case the hypothesis are about the parameters of
the population, the test is said to be parametric. The null hypothesis of any
parametric test can always be written as “the population parameter assumes
some prescribed value”, as in H0 : θ = θ0 , where θ stands for any parameter
and θ0 is some fixed value for it. In case the alternative hypothesis establishes
that the value of a parameter is different from the one established in the null
hypothesis (H0 : θ = θ0 vs. H1 : θ 6= θ0 ), the test is said to be two-sided,
while the test is one-sided when the alternative hypothesis establishes that
9
the true value of the parameter is less than (alternatively greater than) the
prescribed valued from the null hypothesis, H0 : θ = θ0 vs. H1 : θ < θ0 .
The final conclusion of the test is either to reject or not reject (accept)
the null hypothesis, therefore there are two possible sources of error in the
test
• Type I error : Reject the null hypothesis when it is true.
• Type II error : Fail to reject the null hypothesis when it is false.
Each of them has an associated probability
P (Type I error) = P (Reject H0 |H0 ) ; P (Type II error) = P (Accept H0 |H1 ) .
The Type I error is in all cases more important than the Type II and we
will keep its associated probability very low. The (maximal) probability of
Type I error that we are about to tolerate is called significance level and is
denoted by α. Commonly α assumes a value from the set {0.01, 0.05, 0.1},
but in general it can be any positive value close to 0.
Finally, the decision of rejecting or not the null hypothesis is to be taken
based on the available sample information. A test statistic that measures
the distance from the estimator of the parameter (θ̂) to its prescribed value
(θ0 ) is introduced, and based on the distribution of the test statistic and the
significance level α, a critical region (or rejection region) constituted by the
set of values of the test statistic for which the null hypothesis is rejected is
built.
p-value. The p-value is the smallest level of significance that would lead to
rejection of the null hypothesis with the given data.
Relationship between confidence intervals and two-sided paramet-
ric tests. Consider the two-sided parametric test on parameter θ, H0 : θ =
θ0 vs. H1 : θ 6= θ0 with significance level α. The null hypothesis H0 is re-
jected for a given sample if and only if θ0 does not belong to the confidence
interval on θ with confidence level 1 − α obtained from the same sample.
Test on the mean of a normal population (or large sample) with
known variance. Let X ∼ N(µ, σ) with σ known, consider X1 , X2 , . . . , Xn
a random sample of size n.
Null hypothesis, H0 : µ = µ0 ,
10
• Alternative hypothesis H1 : µ 6= µ0 , reject H0 if
x − µ0
√ > zα/2
σ/ n
• Alternative hypothesis H1 : µ > µ0 , reject H0 if
x − µ0
√ > zα
σ/ n
• Alternative hypothesis H1 : µ < µ0 , reject H0 if
x − µ0
√ < −zα
σ/ n
Test on a proportion. Consider a population with a proportion p of
individuals with a given characteristic, and a sample proportion p̂ obtained
from a sample with at least n ≥ 30 observations.
Null hypothesis, H0 : p = p0 ,
• Alternative hypothesis H1 : p 6= p0 , reject H0 if
p̂ − p0
p > zα/2
p0 (1 − p0 )/n
• Alternative hypothesis H1 : p > p0 , reject H0 if
p̂ − p0
p > zα
p0 (1 − p0 )/n
• Alternative hypothesis H1 : p < p0 , reject H0 if
p̂ − p0
p < −zα
p0 (1 − p0 )/n
11
Test on the mean of a normal population with unknown variance.
Let X ∼ N(µ, σ) with σ unknown, consider X1 , X2 , . . . , Xn a random sample
of size n.
Null hypothesis, H0 : µ = µ0 ,
• Alternative hypothesis H1 : µ 6= µ0 , reject H0 if
x − µ0
√ > tn−1,α/2
s/ n
• Alternative hypothesis H1 : µ > µ0 , reject H0 if
x − µ0
√ > tn−1,α
s/ n
• Alternative hypothesis H1 : µ < µ0 , reject H0 if
x − µ0
√ < −tn−1,α
s/ n
Test on the variance of a normal population. Let X ∼ N(µ, σ), con-
sider X1 , X2 , . . . , Xn a random sample of size n.
Null hypothesis, H0 : σ 2 = σ02 ,
• Alternative hypothesis H1 : σ 2 6= σ02 , reject H0 if
(n − 1)s2 2 (n − 1)s2
2
< χn−1,1−α/2 or 2
> χ2n−1,α/2
σ0 σ0
• Alternative hypothesis H1 : σ 2 > σ02 , reject H0 if
(n − 1)s2
2
> χ2n−1,α
σ0
• Alternative hypothesis H1 : σ 2 < σ02 , reject H0 if
(n − 1)s2
2
< χ2n−1,1−α
σ0
12
Test on a parameter based on its Maximum Likelihood Estimator.
Let θ be any parameter, and θ̂M L its maximum likelihood estimator
Null hypothesis, H0 : θ = θ0 ,
• Alternative hypothesis H1 : θ 6= θ0 , reject H0 if
θ̂M L − θ0
> zα/2
σ̂θ̂M L
• Alternative hypothesis H1 : θ > θ0 , reject H0 if
θ̂M L − θ0
> zα
σ̂θ̂M L
• Alternative hypothesis H1 : θ < θ0 , reject H0 if
θ̂M L − θ0
< −zα
σ̂θ̂M L
Test on the difference in proportions of two populations. Consider
two populations, the first of them has a proportion p1 of individuals with a
given characteristic, while the second has a proportion p2 of individuals with
the characteristic. Take two independent random samples, one from each
population, with respective sample proportions p̂1 and p̂2 and sample sizes
n1 , n2 ≥ 30.
Null hypothesis, H0 : p1 = p2 ,
• Alternative hypothesis H1 : p1 6= p2 , reject H0 if
p̂1 − p̂2
p > zα/2
p̂0 (1 − p̂0 )(1/n1 + 1/n2 )
• Alternative hypothesis H1 : p1 > p2 , reject H0 if
p̂1 − p̂2
p > zα
p̂0 (1 − p̂0 )(1/n1 + 1/n2 )
• Alternative hypothesis H1 : p1 < p2 , reject H0 if
p̂1 − p̂2
p < −zα ,
p̂0 (1 − p̂0 )(1/n1 + 1/n2 )
where p̂0 = (n1 p̂1 + n2 p̂2 )/(n1 + n2 ) is the estimator of the population pro-
portion built under the assumption p1 = p2 , that is, H0 .
13
Test on the difference in means of two normal populations with
known variances. Let X ∼ N(µ1 , σ1 ) and Y ∼ N(µ2 , σ2 ), consider
X1 , X2 , . . . , Xn1 a random sample of X of size n1 , and Y1 , Y2 , . . . , Yn2 a ran-
dom sample of Y of size n2 independent of the first sample. The standard
deviations σ1 and σ2 are known.
Null hypothesis, H0 : µ1 − µ2 = δ,
• Alternative hypothesis H1 : µ1 − µ2 6= δ, reject H0 if
(x − y) − δ
p > zα/2
σ12 /n1 + σ22 /n2
• Alternative hypothesis H1 : µ1 − µ2 > δ, reject H0 if
(x − y) − δ
p > zα
σ12 /n1 + σ22 /n2
• Alternative hypothesis H1 : µ1 − µ2 < δ, reject H0 if
(x − y) − δ
p < −zα
σ12 /n1 + σ22 /n2
The same critical regions apply for non-normal populations as long as both
sample sizes are large. It also applies for unknown population variances after
substituting the population variances by the sample variances as long as both
sample sizes are large.
Test on the difference in means of two normal populations with
unknown, but equal variances. Let X ∼ N(µ1 , σ) and Y ∼ N(µ2 , σ),
consider X1 , X2 , . . . , Xn1 a random sample of X of size n1 , and Y1 , Y2 , . . . , Yn2
a random sample of Y of size n2 independent of the first sample. The common
standard deviation σ is unknown.
Null hypothesis, H0 : µ1 − µ2 = δ,
• Alternative hypothesis H1 : µ1 − µ2 6= δ, reject H0 if
(x − y) − δ
p p > tn1 +n2 −2,α/2
((n1 − 1)s1 + (n2 − 1)s22 )/(n1 + n2 − 2) 1/n1 + 1/n2
2
14
• Alternative hypothesis H1 : µ1 − µ2 > δ, reject H0 if
(x − y) − δ
p p > tn1 +n2 −2,α
((n1 − 1)s1 + (n2 − 1)s22 )/(n1 + n2 − 2) 1/n1 + 1/n2
2
• Alternative hypothesis H1 : µ1 − µ2 < δ, reject H0 if
(x − y) − δ
p p < −tn1 +n2 −2,α ,
((n1 − 1)s21 + (n2 − 1)s22 )/(n1 + n2 − 2) 1/n1 + 1/n2
where Sp2 = ((n1 − 1)S12 + (n2 − 1)S22 ) /(n1 + n2 − 2) is an estimator of σ 2
known as the pooled variance.
Test on the variance ratio of two normal populations. Let X ∼
N(µ1 , σ1 ) and Y ∼ N(µ2 , σ2 ), consider X1 , X2 , . . . , Xn1 a random sample of
X of size n1 , and Y1 , Y2 , . . . , Yn1 a random sample of Y of size n2 independent
of the first.
Null hypothesis, H0 : σ12 /σ22 = δ for some δ > 0,
• Alternative hypothesis H1 : σ12 /σ22 6= δ, reject H0 if
s21 −1 S12 −1
δ < fn1 −1,n2 −1,1−α/2 or δ > fn1 −1,n2 −1,α/2
s22 S22
• Alternative hypothesis H1 : σ12 /σ22 > δ, reject H0 if
s21 −1
δ > fn1 −1,+n2 −1,α
s22
• Alternative hypothesis H1 : σ12 /σ22 < δ, reject H0 if
s21 −1
δ < fn1 −1,n2 −1,1−α
s22
Test on the difference in means of two normal populations, paired
data. Let (X, Y ) be a bivariate random vector with E[X] = µ1 , E[Y ] = µ2 ,
and such that X − Y can be assumed to be normally distributed. Consider
a random sample (X1 , Y1 ), . . . , (Xn , Yn ).
Null hypothesis, H0 : µ1 − µ2 = δ,
15
• Alternative hypothesis H1 : µ1 − µ2 6= δ, reject H0 if
d−δ
√ > tn−1,α/2
sd / n
• Alternative hypothesis H1 : µ1 − µ2 > δ, reject H0 if
d−δ
√ > tn−1,α
sd / n
• Alternative hypothesis H1 : µ1 − µ2 < δ, reject H0 if
d−δ
√ < −tn−1,α ,
sd / n
where d is the sample mean difference of the sample x1 − y1 , . . . , xn − yn , and
s2d its sample variance.
16