How do I calculate the P-value of an F-statistic in Excel?

The process of calculating the P-value of an F-statistic in Excel involves using the Excel function “FDIST” or “F.DIST” to calculate the cumulative probability of the F-statistic. This function takes in the F-statistic, degrees of freedom for the numerator and denominator, and a logical value for whether the function returns the cumulative probability of the F-statistic being greater than or equal to the calculated value. The resulting value is the P-value, which can be compared to a predetermined significance level to determine the statistical significance of the F-statistic. This method allows for a quick and efficient way to calculate the P-value, which is an important factor in interpreting the results of statistical tests.

Calculate the P-Value of an F-Statistic in Excel


An F-test produces an F-statistic. To find the p-value associated with an F-statistic in Excel, you can use the following command:

=F.DIST.RT(x, degree_freedom1, degree_freedom2)

where:

  • x: the value of the F-statistic
  • degree_freedom1: numerator degrees of freedom
  • degree_freedom2: denominator degrees of freedom

For example, here is how to find the p-value associated with an F-statistic of 5.4, with numerator degrees of freedom = 2 and denominator degrees of freedom = 9:

P-value from F-statistic in Excel

The p-value is 0.02878.

One of the most common uses of an F-test is for . In the following example, we show how to calculate the p-value of the F-statistic for a regression model.

Example: Calculating p-value from F-statistic

Suppose we have a dataset that shows the total number of hours studied, total prep exams taken, and final exam score received for 12 different students:

Raw data in Excel

If we fit a linear regression model to this data using study_hours and prep_exams as the explanatory variables and score as the response variable, we will get the following output:

F statistic for overall regression in Excel

The F-statistic for the overall regression model is 5.0905. This F-statistic has 2 degrees of freedom for the numerator and 9 degrees of freedom for the denominator.

Excel automatically calculates that the p-value for this F-statistic is 0.0332:

P-value of F-statistic in Excel

In order to calculate this p-value ourselves, we could use the following code:

P-value of F-statistic calculation in Excel

Notice that we get the same p-value as the linear regression output.

x