F.TEST Function (LibreOffice Calc)
The F.TEST function in LibreOffice Calc performs an F-test to compare the variances of two datasets. This guide explains syntax, interpretation, examples, errors, and best practices.
Compatibility
▾| Excel | ✔ |
| Gnumeric | ✔ |
| Google_sheets | ✔ |
| Libreoffice | ✔ |
| Numbers | ✖ |
| Onlyoffice | ✔ |
| Openoffice | ✖ |
| Wps | ✔ |
| Zoho | ✔ |
What the F.TEST Function Does ▾
- Compares variances of two samples
- Returns a p-value based on the F-distribution
- Helps determine whether to use T.TEST type 2 or type 3
- Works across sheets
- Essential for inferential statistics and experimental analysis
F.TEST answers:
“If the two groups truly had equal variances, what is the probability of observing a variance ratio this extreme?”
Syntax ▾
F.TEST(array1; array2)
Where:
array1— first samplearray2— second sample
For two-tailed variance tests, multiply the result by 2.
Interpretation of F.TEST Results ▾
| p-value | Meaning |
|---|---|
| < 0.05 | Variances are significantly different |
| > 0.05 | No evidence of variance difference |
| Near 1 | Variances extremely different in the opposite direction |
If variances differ significantly → use T.TEST type 3
If variances do not differ → type 2 may be appropriate (rare in practice)
Basic Examples ▾
Standard F-test
=F.TEST(A1:A30; B1:B30)
Two-tailed F-test
=2 * F.TEST(A1:A30; B1:B30)
Across sheets
=F.TEST(Sheet1.A1:A50; Sheet2.B1:B50)
Using named ranges
=F.TEST(GroupA; GroupB)
Advanced Examples ▾
F-test ignoring errors
=F.TEST(IF(ISNUMBER(A1:A100); A1:A100); IF(ISNUMBER(B1:B100); B1:B100))
(Confirm with Ctrl+Shift+Enter in older Calc.)
F-test using filtered (visible) data only
Use SUBTOTAL helper column to filter values before passing to F.TEST.
F-test after removing outliers
=F.TEST(FILTER(A1:A100; A1:A100<1000); FILTER(B1:B100; B1:B100<1000))
F-test for experimental groups
=F.TEST(ControlGroup; TreatmentGroup)
F-test before choosing t-test type
=IF(F.TEST(A1:A30; B1:B30) < 0.05; "Use type 3"; "Use type 2")
F-test for log-transformed data
=F.TEST(LN(A1:A30); LN(B1:B30))
How F.TEST Calculates the p-value ▾
- Compute sample variances:
[ s_1^2 = \text{VAR.S}(array1), \quad s_2^2 = \text{VAR.S}(array2) ]
- Compute F-statistic:
[ F = \frac{s_1^2}{s_2^2} ]
- Compute degrees of freedom:
[ df_1 = n_1 - 1, \quad df_2 = n_2 - 1 ]
- Compute p-value using the F-distribution CDF.
Common Errors and Fixes ▾
Err:502 — Invalid argument
Occurs when:
- Arrays contain no numeric values
- Arrays contain fewer than 2 data points
- Variance is zero in one sample
Err:504 — Parameter error
Occurs when:
- Semicolons are incorrect
- Range references malformed
F.TEST returns unexpected value
Possible causes:
- Outliers inflating variance
- Non-normal data (F-test assumes approximate normality)
- Very small sample sizes
- Variance ratio reversed (F.TEST handles this automatically)
Best Practices ▾
- Use F.TEST before choosing t-test type
- Use two-tailed tests when comparing variances symmetrically
- Remove outliers before testing
- Use named ranges for cleaner formulas
- Use log-transformed data when variances scale with magnitude
- Use T.TEST for mean comparison after variance evaluation