You are on page 1of 26

Business Statistics

HYPOTHESIS TESTING
1. POPULATION PARAMETERS I.

György Benoist
2022/2023 Spring
INFERENTIAL STATISTICS
1. ESTIMATION
determining a value of an unknown parameter of the
population by using a sample
2. HYPOTHESIS TESTING
testing a statement (assumption) concerning the population
(parameter or other feature - stochastic relation) with the help
of a sample

2
STEPS
1. Determining the parameter/relation in question
2. Setting up null- and alternative hypotheses
3. Defining test statistic and collecting/calculation necessary
information (data)
4. Calculating test-function
test statistic
5. Calculating critical value(s)/rejection region
6. Decision making
7. Answering the original question/statement

3
Hypothesis testing

PARAMETRIC NON-PARAMETRIC REGRESSION RELATED


(population parameters) (population distibution, (correlation and statistical
independency) model)

1 POPULATION 2 POPULATIONS

4
PARAMETRIC

5
POPULATION PARAMETERS
• expected value (μ)
„the average working time is 2 years”
• proportion (P)
„40% of the customers spend more than 2000 HUF”
„the rate of red boxes is at least 200”
• standard deviation (σ)
„the standard deviation of filling weights is at most 5 grams”

6
HYPOTHESES
Null-hypothesis Alternative hypothesis
H0 H1 (HA)
Θ = Θ0 Θ ǂ Θ0 two-tailed (two-sided)
Θ ≥ Θ0 Θ < Θ0 one-tailed (one-sided) left/lower tailed (left sided)
Θ ≤ Θ0 Θ > Θ0 one-tailed (one-sided) right/upper tailed (right sided)

7
TEST STATISTIC
= a tool for testing the hypothesis
• its value depends on the sample
• two components:
• value of test-function
• critical value(s) rejecting region
• significance level (α): the probability that the test-function falls
into the rejection region
• testing one or two population parameters

8
1 POPULATION

9
TEST-FUNCTIONS
Testing for the population mean (expected value; μ)
• large sample (n ≥ 100) xത − m0
z=
s/ n
• normal distribution, small sample, standard deviation of the
population (σ) is known xത − m0
z=
σ/ n
• normal distribution, small sample, standard deviation of the
population (σ) is unknown
xത − m0
t=
s/ n
10
TEST-FUNCTIONS
Testing for the population proportion (P)

• only when n ≥ 100!!!


p − P0
z=
P0 ∗ Q0 /n

where Q 0 = 1 − P0

11
TEST-FUNCTIONS
Testing for the population standard deviation (variance: σ2)

• only in case of normal distribution!!!


n − 1 ∗ s 2
χ2 =
σ20

12
CRITICAL VALUE(S) – REJECTING REGION(S)
H0 : parameter = value
Rejection region = α H1 : parameter ǂ value
(2 * α/2)
two-tailed test
1-α

α/2 α/2

cl cu
Reject H0 Fail to reject (do not reject) H0 Reject H0

13
CRITICAL VALUE(S) – REJECTING REGION(S)
H0 : parameter = (≥) value
Rejection region = α H1 : parameter < value

Lower tail test


1-α

cl
Reject H0 Fail to reject (do not reject) H0

14
CRITICAL VALUE(S) – REJECTING REGION(S)
H0 : parameter = (≤) value
Rejection region = α H1 : parameter > value

Upper tail test


1-α

cu
Fail to reject (do not reject) H0 Reject H0

15
FUNCTIONS DETERMINING CRITICAL VALUES
two-tailed one-tailed degree of freedom
Parameter function
lower (cl) upper (cu) lower (cl) upper (cu) one population two populations
NORM.S.INV - -
Expected value (μ)
T.INV n-1 n1+n2-2
α 1-α
Porportion (P) NORM.S.INV α/2 1-α/2 - -
CHISQ.INV n-1
Standard deviation (σ)
F.INV n1-1 and n2-1

in case of z and t functions: cl = - cu

16
DECISION
H0 : parameter = value
H1 : parameter ǂ value

„The test function does not fall into the


1-α rejection region, therefore we fail to
reject the H0”

α/2 α/2
value of the test-
function

cl cu
Reject H0 Fail to reject (do not reject) H0 Reject H0

17
DECISION
• always about null-hypothesis! (reject or fail to reject)
(never „accepting”)
in research: discredit the statement of H0 and supporting the
statement in H1
• it is probabilistic (another sample could lead to opposite decision)

possibility to draw an incorrect conclusion

18
ERRORS
Decision Actual situation
(conclusion) H 0 is true H 0 is false
Correct decision
Fail to reject H0 Type II error (β)
(1-α)
Correct decision
Reject H0 Type I error (α)
(1-β)

The two types of errors can not happen at the same time.
If Type I error probability (α) is decreasing, than Type II error probability (β) is increasing.

19
EXAMPLE 1

An entrepreneur repairing electronic devices was curious the evolution of operation


and malfunction of a given product. He registered the length of operation time (in
month) of 20 randomly chosen product (same producers, same type) until the first
failure:
22 19 11 34 26 9 14 32 6 15
16 26 30 26 18 7 11 19 9 10
From previous survey it is known that the length of operation time follows a normal
distribution, the standard deviation is 8.5 months.
a) Test at 5% significance level the statement that the average length of the
operation time of the given product until the first failure is at least 2 years.
b) According to the quality requirements the standard deviation of the average
operation time should be at most 10 months. Test whether this requirement is
fulfilled or not based on the sample.
20
a) Test at 5% significance level the statement that the average length of the
operation time of the given product until the first failure is at least 2 years.

parameter: expected value (μ)


H0: μ = 24 (= 2 years) m0 [≥]
H1: μ < 24

sample size (n) 20


standard deviation (σ) 8.5
average length of operation time (𝑥)ҧ 18 (months)
xത − m0 18 − 24
test function z= = = −3.16
σ/ n 8.5/ 20
21
a) Test at 5% significance level the statement that the average length of the
operation time of the given product until the first failure is at least 2 years.
H0: μ = 24
one-tailed test: „only one” rejection region (α)
H1: μ < 24
lower critical value

test function -3.16


z
lower critical value (cl) = - upper critical value (cu)

cl = - NORM.S.INV(1-α) = -1.6449
cl = NORM.S.INV(α)

decision: H0 is rejected 22
b) According to the quality requirements the standard deviation of the average
operation time should be at most 10 months. Test whether this requirement is
fulfilled or not based on the sample.
parameter: standard deviation (σ)
H0: σ = 10 σ0 [≤]
H1: σ > 10

sample size (n) 20


standard deviation (s) 8.66

n − 1 ∗ s 2
test function χ2 = 19 ∗ 8.662
= = 14.24
σ20 10 2
23
b) According to the quality requirements the standard deviation of the average
operation time should be at most 10 months. Test whether this requirement is
fulfilled or not based on the sample.
H0: σ = 10
one-tailed test: „only one” rejection region (α)
H1: σ > 10
upper critical value
test function: 14.24

cu = CHISQ.INV(1-α;n-1) = 30.14

decision: H0 is failed to rejected cu 24


Fail to reject (do not reject) H0 Reject H0
EXAMPLE 2

In the historical downtown of a town a new modern office building is planned


to be built. The local government gives green light only when majority of the
inhabitants would support the plan. Therefore a random sample of 400
persons were asked and 208 of them was supporting it.
Determine at 5% significance level the decision of the municipal government.

parameter: proportion (P)


H0: P = 0.5 [≤]
H1: P > 0.5
sample size (n) 400 p = 208/400 = 0.52

p − P0 0.52−0.5
test function z= = = 0.8
0.5∗(1−0.5)
P0 ∗ Q0 /n 400
25
H0: P = 0.5
one-tailed test: „only one” rejection region (α)
H1: P > 0.5
upper critical value

z test function 0.8

cu = NORM.S.INV(1-α) = 1.6449

decision: H0 is failed to reject

26

You might also like