TD_FTest Usage Notes | F Test - TD_FTest Usage Notes - Teradata Vantage

Teradata® VantageCloud Lake

Deployment
VantageCloud
Edition
Lake
Product
Teradata Vantage
Published
January 2023
ft:locale
en-US
ft:lastEdition
2024-12-11
dita:mapPath
phg1621910019905.ditamap
dita:ditavalPath
pny1626732985837.ditaval
dita:id
phg1621910019905

In statistical analysis, the F-test is a commonly used hypothesis test to determine whether two population variances are equal. It is based on the F distribution, which is a probability distribution that arises in the analysis of variance (ANOVA) models.

The F-test is typically used in situations where we want to compare the variability of two sets of data or test whether a particular variable has a significant effect on the outcome of a study. It works by calculating the ratio of two variances and comparing it to a critical value obtained from the F distribution.

Assumptions

  • Populations from which samples are drawn are normally distributed.
  • Populations are independent of each other.
  • Data is numeric.

Test Type

  • One-tailed (lower and upper-tailed) or two-tailed (your choice)
  • Two-sample
  • Unpaired

Computational Method

The F-test is used to test the Null hypothesis σ2 = sigma0_sq in various applications. For example, you might need to test the variability in the measurement of the thickness of a manufactured part in a factory. If the thickness is not equal to a certain thickness (sigma0_sq ) then you can conclude that the manufacturing process is uncontrolled. The types of hypothesis are as follows:

H0: σ2 = sigma0_sq

versus

H1: σ2 > sigma0_sq (upper-tailed)

or

H1: σ2 < sigma0_sq (lower-tailed)

or

H1: σ2sigma0_sq (two-tailed)

Let x1, x2,....xn be a random sample. To test the hypotheses, the test statistic is calculated as:


F-Test formula

where s2_formula

The statistic χ2 follows an F distribution with n-1 degrees of freedom.

For the one-sided upper-tailed test σ2 > sigma0_sq the Null hypothesis H0 is rejected if H0_onesided_right_tailed_test.

For the one-sided lower-tailed test σ2 < sigma0_sq, the Null hypothesis H0 is rejected if H0_onesided_left_tailed_rejection.

For the two-sided alternative σ2sigma0_sq, the Null hypothesis H0 is rejected if


2_sided_null_hypothesis_rejected
Also, the F-test is used to test if the variances of two populations are equal. The F-test can have the following tests:
  • One-tailed test: The test is used to determine if the variance of one population is either greater than (upper-tailed) or less than (lower-tailed) the variance of another population.
  • Two-tailed test: The test is used to determine significant differences in variances of the two populations and tests the Null hypothesis (H0) against the alternative hypothesis (H1) to find out if the variances are not equal.
Let x1, x2,....xn1 ~Ɲ (µ1, σ2) and y1, y2,....yn2 ~Ɲ (µ2, σ2) be random samples from two independent populations. The corresponding sample means and variances are as follows:
  • Sample Means Formula: sample_means_x_formula
  • Sample Variance Formula: sample_variance_y_formula
  • Sample Variance Formula for s1_square and s2_square: sample_variance_s1_formula and sample_variance_s2_formula

In the following calculation, assume that sample 1 has a larger variance than sample 2. If sample 2 has a larger variance than sample 1, switch the samples and apply the same formula.

H0: sigma1_sq = sigma2_sq

versus

H1: sigma1_sq > sigma2_sq

or

sigma1_sq < sigma2_sq

The test statistic for the one-sided upper tailed test (sigma1_sq > sigma2_sq) is calculated as:


1_sided_right_tailed_test

where: n1-1 and n2-1 are degrees of freedom corresponding to sample 1 and sample 2.

The Null hypothesis H0 is rejected if 1_sided_right_tailed_test_H0_rejected.

The test statistic for the one-sided lower-tailed test (sigma1_sq < sigma2_sq) is calculated as:


1_sided_left_tailed_test_stats

The Null hypothesis H0 is rejected if 1_sided_left_tailed_test_stats_H0_rejected.

For the two-sided hypothesis test:

H0: sigma1_sq = sigma2_sq

versus

H1: sigma1_sqsigma2_sq

The Null hypothesis H0 is rejected if:


H0 rejected two-sided test

The two-tailed test is based on the upper tail of the F-distribution.