# Hypothesis Testing – Distribution

of 28
/28

Embed Size (px)

### Transcript of Hypothesis Testing – Distribution

Hypothesis Testing -- Distribution - STATISTICS -- Lecture no.
12Hypothesis Testing – Distribution STATISTICS – Lecture no.
12

Jir Neubauer

Department of Econometrics FEM UO Brno office 69a, tel. 973 442029 email:[email protected]

5. 1. 2010

Hypothesis Testing

a population parameters (µ, σ2, π, λ, . . . ),

a distribution (normal, Poisson, . . . ).

Hypothesis Testing

a population parameters (µ, σ2, π, λ, . . . ),

a distribution (normal, Poisson, . . . ).

Hypothesis Testing

A null hypothesis H is a claim (or statement) about a population parameter that is assumed to be true until it is declared false . . . for example

H : µ = µ0,

An alternative hypothesis A is a claim about a population parameter that will be true if the null hypothesis is false

1. A : µ 6= µ0 → both-sided test, 2. A : µ > µ0 → one-sided test, 3. A : µ < µ0 → one-sided test.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Hypothesis Testing

A null hypothesis H is a claim (or statement) about a population parameter that is assumed to be true until it is declared false . . . for example

H : µ = µ0,

An alternative hypothesis A is a claim about a population parameter that will be true if the null hypothesis is false

1. A : µ 6= µ0 → both-sided test,

2. A : µ > µ0 → one-sided test, 3. A : µ < µ0 → one-sided test.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Hypothesis Testing

A null hypothesis H is a claim (or statement) about a population parameter that is assumed to be true until it is declared false . . . for example

H : µ = µ0,

An alternative hypothesis A is a claim about a population parameter that will be true if the null hypothesis is false

1. A : µ 6= µ0 → both-sided test, 2. A : µ > µ0 → one-sided test,

3. A : µ < µ0 → one-sided test.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Hypothesis Testing

A null hypothesis H is a claim (or statement) about a population parameter that is assumed to be true until it is declared false . . . for example

H : µ = µ0,

An alternative hypothesis A is a claim about a population parameter that will be true if the null hypothesis is false

1. A : µ 6= µ0 → both-sided test, 2. A : µ > µ0 → one-sided test, 3. A : µ < µ0 → one-sided test.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Hypothesis Testing

decision about H prob. prob.

not reject correct decision 1− α type II error β

reject type I error α correct decision 1− β

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Hypothesis Testing

If we reject the null hypothesis which is true, we call this type I error. The probability of this error is α ⇒ a significance level. A number 1− α is probability that we do not reject the true hypothesis H.

If we accept the null hypothesis although is false, we call this type II error. The probability of this error is β. A number 1− β ⇒ a power of the test is the probability that we reject the null hypothesis H, if it is false.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Hypothesis Testing

If we reject the null hypothesis which is true, we call this type I error. The probability of this error is α ⇒ a significance level. A number 1− α is probability that we do not reject the true hypothesis H.

If we accept the null hypothesis although is false, we call this type II error. The probability of this error is β. A number 1− β ⇒ a power of the test is the probability that we reject the null hypothesis H, if it is false.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Hypothesis Testing

To test the null hypothesis we use a function of a random sample T = T (x1, x2, . . . , xn), so called test statistic, which has under the null hypothesis H known distribution (usually t, u, χ2,F ). We divide the all possible values of the test statistic into

W1−α - nonrejection region of H – the set of values connected with the hypothesis H,

Wα - rejection region of H – the set of values connected with the hypothesis A.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Hypothesis Testing

To test the null hypothesis we use a function of a random sample T = T (x1, x2, . . . , xn), so called test statistic, which has under the null hypothesis H known distribution (usually t, u, χ2,F ). We divide the all possible values of the test statistic into

W1−α - nonrejection region of H – the set of values connected with the hypothesis H,

Wα - rejection region of H – the set of values connected with the hypothesis A.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Hypothesis Testing

To test the null hypothesis we use a function of a random sample T = T (x1, x2, . . . , xn), so called test statistic, which has under the null hypothesis H known distribution (usually t, u, χ2,F ). We divide the all possible values of the test statistic into

W1−α - nonrejection region of H – the set of values connected with the hypothesis H,

Wα - rejection region of H – the set of values connected with the hypothesis A.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Steps to Perform a Test of Hypothesis

1. State the null and alternative hypothesis H and A.

2. Select a significance level α (usually 0.05 a 0.01).

3. Choose the test statistic.

4. Determine the rejection region Wα.

5. Calculate the value of the test statistic.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Steps to Perform a Test of Hypothesis

1. State the null and alternative hypothesis H and A.

2. Select a significance level α (usually 0.05 a 0.01).

3. Choose the test statistic.

4. Determine the rejection region Wα.

5. Calculate the value of the test statistic.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Steps to Perform a Test of Hypothesis

1. State the null and alternative hypothesis H and A.

2. Select a significance level α (usually 0.05 a 0.01).

3. Choose the test statistic.

4. Determine the rejection region Wα.

5. Calculate the value of the test statistic.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Steps to Perform a Test of Hypothesis

1. State the null and alternative hypothesis H and A.

2. Select a significance level α (usually 0.05 a 0.01).

3. Choose the test statistic.

4. Determine the rejection region Wα.

5. Calculate the value of the test statistic.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Steps to Perform a Test of Hypothesis

1. State the null and alternative hypothesis H and A.

2. Select a significance level α (usually 0.05 a 0.01).

3. Choose the test statistic.

4. Determine the rejection region Wα.

5. Calculate the value of the test statistic.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Steps to Perform a Test of Hypothesis

6. Make a decision:

If the value of the test statistic falls in the rejection region, we reject the null hypothesis H and say that we accept the alternative hypothesis A with the probability 1− α. If the value of the test statistic falls in the nonrejection region, we do not reject the null hypothesis H.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Steps to Perform a Test of Hypothesis

6. Make a decision:

If the value of the test statistic falls in the rejection region, we reject the null hypothesis H and say that we accept the alternative hypothesis A with the probability 1− α.

If the value of the test statistic falls in the nonrejection region, we do not reject the null hypothesis H.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Steps to Perform a Test of Hypothesis

6. Make a decision:

If the value of the test statistic falls in the rejection region, we reject the null hypothesis H and say that we accept the alternative hypothesis A with the probability 1− α. If the value of the test statistic falls in the nonrejection region, we do not reject the null hypothesis H.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Chi-Square Goodness of Fit Test Tests of Skewness and Kurtosis Compound Tests of Skewness and Kurtosis

Chi-Square Goodness of Fit Test

We divide values of a random sample x1, x2, . . . , xn into k disjunct classes, where nj , j = 1, 2, . . . , k, is frequency of the class j and πj

is a probability that the random variable X has value from the class j , calculated on condition that X has an assumed distribution.

The main idea of the test is to compare relative frequencies nj/n with theoretical probabilities πj .

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Chi-Square Goodness of Fit Test Tests of Skewness and Kurtosis Compound Tests of Skewness and Kurtosis

Chi-Square Goodness of Fit Test

We state the null and alternative hypothesis: H : the random X has an assumed distribution → A : the random X has not an assumed distribution. The test statistic is

χ2 = k∑

j=1

nπj ,

which has under the null hypothesis H for large n (asymptotically) a Pearson χ2-distribution with ν = k − c − 1 degrees of freedom, where c is a number of estimated parameters of the assumed distribution. A rejection region is

Wα = { χ2, χ2 ≥ χ2

,

where χ2 1−α(ν) is a quantile of the Pearson χ2-distribution.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Chi-Square Goodness of Fit Test Tests of Skewness and Kurtosis Compound Tests of Skewness and Kurtosis

Chi-Square Goodness of Fit Test

Recommendation:

nπj > 5, j = 1, 2, . . . , k.

If this condition is not satisfied, it is necessary to join the classes.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Chi-Square Goodness of Fit Test Tests of Skewness and Kurtosis Compound Tests of Skewness and Kurtosis

Tests of Skewness and Kurtosis

The normal distribution has α3 = 0 a α4 = 0. We can use these properties to test normality. We calculate a sample skewness and kurtosis (they are estimates of α3 and α4)

α3 = a3 = 1

ns4 n

n∑ i=1

(xi − x)4 − 3.

We state hypothesis: H1 : α3 = 0 → A1 : α3 6= 0 H2 : α4 = 0 → A2 : α4 6= 0

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Chi-Square Goodness of Fit Test Tests of Skewness and Kurtosis Compound Tests of Skewness and Kurtosis

Tests of Skewness and Kurtosis

1. H1 : α3 = 0 → A1 : α3 6= 0 Test statistic is

u3 = a3√ D(a3)

(n + 1)(n + 3) ,

which has under the null hypothesis H1 asymptotically normal distribution N(0, 1). A rejection region is

Wα = {

} ,

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Chi-Square Goodness of Fit Test Tests of Skewness and Kurtosis Compound Tests of Skewness and Kurtosis

Tests of Skewness and Kurtosis

2. H2 : α4 = 0 → A2 : α4 6= 0 Test statistic is

u4 = a4 + 6

n+1√ D(a4)

(n + 1)2(n + 3)(n + 5) ,

which has under the null hypothesis H2 asymptotically normal distribution N(0, 1). A rejection region is

Wα = {

} ,

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Chi-Square Goodness of Fit Test Tests of Skewness and Kurtosis Compound Tests of Skewness and Kurtosis

Compound Tests of Skewness and Kurtosis

We state hypothesis: H : a random variable X has a normal distribution → A : a random variable X has not a normal distribution. Test statistic is

C = u2 3 + u2

which has under the null hypothesis H approximately χ2

distribution with two degrees of freedom. u3 and u4 are test statistics defined above. A rejection region is

Wα = { C ,C ≥ χ2

,

where χ2 1−α(2) is a quantile of the Pearson χ2-distribution.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing

Compound Tests of Skewness and Kurtosis

Jir Neubauer

Department of Econometrics FEM UO Brno office 69a, tel. 973 442029 email:[email protected]

5. 1. 2010

Hypothesis Testing

a population parameters (µ, σ2, π, λ, . . . ),

a distribution (normal, Poisson, . . . ).

Hypothesis Testing

a population parameters (µ, σ2, π, λ, . . . ),

a distribution (normal, Poisson, . . . ).

Hypothesis Testing

A null hypothesis H is a claim (or statement) about a population parameter that is assumed to be true until it is declared false . . . for example

H : µ = µ0,

An alternative hypothesis A is a claim about a population parameter that will be true if the null hypothesis is false

1. A : µ 6= µ0 → both-sided test, 2. A : µ > µ0 → one-sided test, 3. A : µ < µ0 → one-sided test.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Hypothesis Testing

A null hypothesis H is a claim (or statement) about a population parameter that is assumed to be true until it is declared false . . . for example

H : µ = µ0,

An alternative hypothesis A is a claim about a population parameter that will be true if the null hypothesis is false

1. A : µ 6= µ0 → both-sided test,

2. A : µ > µ0 → one-sided test, 3. A : µ < µ0 → one-sided test.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Hypothesis Testing

A null hypothesis H is a claim (or statement) about a population parameter that is assumed to be true until it is declared false . . . for example

H : µ = µ0,

An alternative hypothesis A is a claim about a population parameter that will be true if the null hypothesis is false

1. A : µ 6= µ0 → both-sided test, 2. A : µ > µ0 → one-sided test,

3. A : µ < µ0 → one-sided test.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Hypothesis Testing

A null hypothesis H is a claim (or statement) about a population parameter that is assumed to be true until it is declared false . . . for example

H : µ = µ0,

An alternative hypothesis A is a claim about a population parameter that will be true if the null hypothesis is false

1. A : µ 6= µ0 → both-sided test, 2. A : µ > µ0 → one-sided test, 3. A : µ < µ0 → one-sided test.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Hypothesis Testing

decision about H prob. prob.

not reject correct decision 1− α type II error β

reject type I error α correct decision 1− β

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Hypothesis Testing

If we reject the null hypothesis which is true, we call this type I error. The probability of this error is α ⇒ a significance level. A number 1− α is probability that we do not reject the true hypothesis H.

If we accept the null hypothesis although is false, we call this type II error. The probability of this error is β. A number 1− β ⇒ a power of the test is the probability that we reject the null hypothesis H, if it is false.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Hypothesis Testing

If we reject the null hypothesis which is true, we call this type I error. The probability of this error is α ⇒ a significance level. A number 1− α is probability that we do not reject the true hypothesis H.

If we accept the null hypothesis although is false, we call this type II error. The probability of this error is β. A number 1− β ⇒ a power of the test is the probability that we reject the null hypothesis H, if it is false.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Hypothesis Testing

To test the null hypothesis we use a function of a random sample T = T (x1, x2, . . . , xn), so called test statistic, which has under the null hypothesis H known distribution (usually t, u, χ2,F ). We divide the all possible values of the test statistic into

W1−α - nonrejection region of H – the set of values connected with the hypothesis H,

Wα - rejection region of H – the set of values connected with the hypothesis A.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Hypothesis Testing

To test the null hypothesis we use a function of a random sample T = T (x1, x2, . . . , xn), so called test statistic, which has under the null hypothesis H known distribution (usually t, u, χ2,F ). We divide the all possible values of the test statistic into

W1−α - nonrejection region of H – the set of values connected with the hypothesis H,

Wα - rejection region of H – the set of values connected with the hypothesis A.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Hypothesis Testing

To test the null hypothesis we use a function of a random sample T = T (x1, x2, . . . , xn), so called test statistic, which has under the null hypothesis H known distribution (usually t, u, χ2,F ). We divide the all possible values of the test statistic into

W1−α - nonrejection region of H – the set of values connected with the hypothesis H,

Wα - rejection region of H – the set of values connected with the hypothesis A.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Steps to Perform a Test of Hypothesis

1. State the null and alternative hypothesis H and A.

2. Select a significance level α (usually 0.05 a 0.01).

3. Choose the test statistic.

4. Determine the rejection region Wα.

5. Calculate the value of the test statistic.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Steps to Perform a Test of Hypothesis

1. State the null and alternative hypothesis H and A.

2. Select a significance level α (usually 0.05 a 0.01).

3. Choose the test statistic.

4. Determine the rejection region Wα.

5. Calculate the value of the test statistic.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Steps to Perform a Test of Hypothesis

1. State the null and alternative hypothesis H and A.

2. Select a significance level α (usually 0.05 a 0.01).

3. Choose the test statistic.

4. Determine the rejection region Wα.

5. Calculate the value of the test statistic.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Steps to Perform a Test of Hypothesis

1. State the null and alternative hypothesis H and A.

2. Select a significance level α (usually 0.05 a 0.01).

3. Choose the test statistic.

4. Determine the rejection region Wα.

5. Calculate the value of the test statistic.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Steps to Perform a Test of Hypothesis

1. State the null and alternative hypothesis H and A.

2. Select a significance level α (usually 0.05 a 0.01).

3. Choose the test statistic.

4. Determine the rejection region Wα.

5. Calculate the value of the test statistic.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Steps to Perform a Test of Hypothesis

6. Make a decision:

If the value of the test statistic falls in the rejection region, we reject the null hypothesis H and say that we accept the alternative hypothesis A with the probability 1− α. If the value of the test statistic falls in the nonrejection region, we do not reject the null hypothesis H.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Steps to Perform a Test of Hypothesis

6. Make a decision:

If the value of the test statistic falls in the rejection region, we reject the null hypothesis H and say that we accept the alternative hypothesis A with the probability 1− α.

If the value of the test statistic falls in the nonrejection region, we do not reject the null hypothesis H.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Steps to Perform a Test of Hypothesis

6. Make a decision:

If the value of the test statistic falls in the rejection region, we reject the null hypothesis H and say that we accept the alternative hypothesis A with the probability 1− α. If the value of the test statistic falls in the nonrejection region, we do not reject the null hypothesis H.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Chi-Square Goodness of Fit Test Tests of Skewness and Kurtosis Compound Tests of Skewness and Kurtosis

Chi-Square Goodness of Fit Test

We divide values of a random sample x1, x2, . . . , xn into k disjunct classes, where nj , j = 1, 2, . . . , k, is frequency of the class j and πj

is a probability that the random variable X has value from the class j , calculated on condition that X has an assumed distribution.

The main idea of the test is to compare relative frequencies nj/n with theoretical probabilities πj .

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Chi-Square Goodness of Fit Test Tests of Skewness and Kurtosis Compound Tests of Skewness and Kurtosis

Chi-Square Goodness of Fit Test

We state the null and alternative hypothesis: H : the random X has an assumed distribution → A : the random X has not an assumed distribution. The test statistic is

χ2 = k∑

j=1

nπj ,

which has under the null hypothesis H for large n (asymptotically) a Pearson χ2-distribution with ν = k − c − 1 degrees of freedom, where c is a number of estimated parameters of the assumed distribution. A rejection region is

Wα = { χ2, χ2 ≥ χ2

,

where χ2 1−α(ν) is a quantile of the Pearson χ2-distribution.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Chi-Square Goodness of Fit Test Tests of Skewness and Kurtosis Compound Tests of Skewness and Kurtosis

Chi-Square Goodness of Fit Test

Recommendation:

nπj > 5, j = 1, 2, . . . , k.

If this condition is not satisfied, it is necessary to join the classes.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Chi-Square Goodness of Fit Test Tests of Skewness and Kurtosis Compound Tests of Skewness and Kurtosis

Tests of Skewness and Kurtosis

The normal distribution has α3 = 0 a α4 = 0. We can use these properties to test normality. We calculate a sample skewness and kurtosis (they are estimates of α3 and α4)

α3 = a3 = 1

ns4 n

n∑ i=1

(xi − x)4 − 3.

We state hypothesis: H1 : α3 = 0 → A1 : α3 6= 0 H2 : α4 = 0 → A2 : α4 6= 0

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Chi-Square Goodness of Fit Test Tests of Skewness and Kurtosis Compound Tests of Skewness and Kurtosis

Tests of Skewness and Kurtosis

1. H1 : α3 = 0 → A1 : α3 6= 0 Test statistic is

u3 = a3√ D(a3)

(n + 1)(n + 3) ,

which has under the null hypothesis H1 asymptotically normal distribution N(0, 1). A rejection region is

Wα = {

} ,

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Chi-Square Goodness of Fit Test Tests of Skewness and Kurtosis Compound Tests of Skewness and Kurtosis

Tests of Skewness and Kurtosis

2. H2 : α4 = 0 → A2 : α4 6= 0 Test statistic is

u4 = a4 + 6

n+1√ D(a4)

(n + 1)2(n + 3)(n + 5) ,

which has under the null hypothesis H2 asymptotically normal distribution N(0, 1). A rejection region is

Wα = {

} ,

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing Hypothesis Testing – Distribution

Chi-Square Goodness of Fit Test Tests of Skewness and Kurtosis Compound Tests of Skewness and Kurtosis

Compound Tests of Skewness and Kurtosis

We state hypothesis: H : a random variable X has a normal distribution → A : a random variable X has not a normal distribution. Test statistic is

C = u2 3 + u2

which has under the null hypothesis H approximately χ2

distribution with two degrees of freedom. u3 and u4 are test statistics defined above. A rejection region is

Wα = { C ,C ≥ χ2

,

where χ2 1−α(2) is a quantile of the Pearson χ2-distribution.

Jir Neubauer Hypothesis Testing – Distribution

Hypothesis Testing

Compound Tests of Skewness and Kurtosis