Google Sheets T.DIST Function: A How-To Guide
In this article
The T.DIST function in Google Sheets returns the left-tailed Student's t-distribution for a given value, degrees of freedom, and a logical flag for cumulative vs. probability density. To use it, click an empty cell, type =T.DIST(x, degrees_freedom, cumulative), and press Enter. For example, =T.DIST(1.5, 10, TRUE) gives the cumulative probability up to 1.5 on a t-distribution with 10 degrees of freedom. This guide walks through the syntax, practical examples, common errors, and fixes so you can use it confidently for hypothesis testing, confidence intervals, and small-sample statistics.
What You'll Need
- A Google account with access to Google Sheets (desktop browser or the Sheets mobile app).
- A dataset or a set of numbers you want to analyze (sample size, t-statistic, or degrees of freedom).
- Basic familiarity with cell references and formulas in Sheets.
- Your degrees of freedom value, which is usually sample size minus one for a one-sample t-test.
Step-by-Step
- Open your spreadsheet. Go to Google Sheets and open an existing file or create a blank one. The function works the same in the browser and in the mobile app, though the formula bar is easier to use on desktop.
- Select the cell for the result. Click an empty cell where you want the probability to appear. This keeps your data and output separate.
- Start the formula. Type
=T.DIST(in the cell or in the formula bar. As you type, Sheets may show a tooltip with the argument order. If you see a suggestion list, you can click T.DIST to insert it. - Enter the x value. This is the t-value you are evaluating. You can type a number directly, such as
1.5, or reference a cell likeA2. The x value can be negative; the left-tailed distribution handles it correctly. - Add a comma and enter degrees of freedom. Degrees of freedom must be a positive number. For a one-sample t-test with 15 observations, use 14. Type
14or reference a cell such asB2. - Add a comma and choose cumulative or density. Type
TRUEfor the cumulative distribution (the probability that a value is less than or equal to x). TypeFALSEfor the probability density at x. Most hypothesis-testing work uses TRUE. - Close the parenthesis and press Enter. Your formula should look like
=T.DIST(1.5, 14, TRUE). The cell displays the left-tailed probability. If you used FALSE, you get the height of the density curve at that point, not a probability. - Check the result against a known value. For a quick sanity check,
=T.DIST(0, 10, TRUE)should return 0.5 because the t-distribution is symmetric around zero. If you get 0.5, the formula is working. - Copy the formula down or across if needed. Use the fill handle to drag the formula to other rows. Use absolute references (like
$B$2) for degrees of freedom if it should stay fixed while x changes. - Format the output. Select the result cells and use Format > Number > Percent if you want to read probabilities as percentages, or increase decimal places with the toolbar buttons for more precision.
Common Mistakes
- Using T.DIST when you need a two-tailed p-value. T.DIST is left-tailed only. For a two-tailed test, use
=T.DIST.2T(x, degrees_freedom)or double the left-tail result when appropriate. Mixing these up flips your conclusion. - Passing a negative x to T.DIST.2T. The two-tailed variant requires x to be non-negative. If your t-statistic is negative, use the absolute value or compute the left tail and double it.
- Entering degrees of freedom as a decimal or zero. Degrees of freedom must be a positive integer in most practical cases. A zero or negative value returns an error.
- Forgetting the cumulative argument. T.DIST requires three arguments. Omitting the third gives a formula parse error, not a default.
- Confusing density with probability. Setting cumulative to FALSE returns a density value that can exceed 1. That is not a probability and should not be interpreted as one.
- Using the wrong degrees of freedom for a two-sample test. For two independent samples, the degrees of freedom are not simply n1 + n2 - 2 unless you assume equal variances. Use the correct formula or a built-in test function.
Tips
- Use cell references instead of hard-coded numbers so you can update inputs without rewriting formulas.
- Label your input cells clearly (x, df, cumulative) so the formula is readable later.
- For a right-tailed probability, compute
=1 - T.DIST(x, df, TRUE). This is useful when your alternative hypothesis is “greater than.” - Combine T.DIST with T.INV or T.INV.2T to build confidence intervals: find the critical t-value, then multiply by the standard error.
- If you are working with very large samples, the t-distribution approaches the normal distribution, but T.DIST still works and is more accurate for small samples.
- Use the formula bar to inspect long formulas; the cell may show a rounded value while the full precision is stored.
Troubleshooting
If you see #NUM!, check that degrees of freedom is greater than zero and that x is a valid number. If you see #VALUE!, one of your arguments is text instead of a number or logical value; make sure TRUE/FALSE are unquoted and cell references point to numeric cells. If you see #NAME?, the function name may be misspelled or you may be using a locale that requires a different separator; try typing the formula again from the suggestion list. If the result looks wrong, verify whether you need a one-tailed or two-tailed probability and whether cumulative should be TRUE. If the formula works in one cell but not when copied, check for relative references that shifted unexpectedly; lock the degrees of freedom cell with dollar signs. If the mobile app behaves differently, remember that some function suggestions and formula bar features vary by version and device; typing the full formula manually usually resolves it.
Frequently Asked Questions
What is the difference between T.DIST and T.DIST.2T?
T.DIST returns the left-tailed cumulative probability or the density at x. T.DIST.2T returns the two-tailed probability and requires x to be non-negative. Use T.DIST for one-sided tests and T.DIST.2T for two-sided tests.
Can T.DIST handle negative x values?
Yes. T.DIST accepts negative x and returns the correct left-tail probability. T.DIST.2T does not accept negative x; use the absolute value or a different approach.
What degrees of freedom should I use?
For a one-sample t-test, use n - 1. For a paired test, use the number of pairs minus one. For two independent samples, the calculation depends on whether you assume equal variances; use the appropriate formula or a built-in test function rather than guessing.
Why does T.DIST return a value greater than 1 when cumulative is FALSE?
With cumulative set to FALSE, T.DIST returns a probability density, which is the height of the curve at x. Density values are not probabilities and can exceed 1, especially for small degrees of freedom.
Does T.DIST work in the Google Sheets mobile app?
Yes, the function is available in the Sheets mobile app. The formula bar and function suggestions may differ slightly by version and device, but typing the full formula works the same way.
How do I get a right-tailed probability?
Use =1 - T.DIST(x, df, TRUE). This gives the probability of observing a value greater than x under the t-distribution.