# TTEST Function

> Return the probability of a Student's t-test with the TTEST compatibility function of TX Sheet Control: tails, test types, #NUM! errors and an example formula.

- **Product:** TX Sheet Control
- **Section:** Documentation
- **Kind:** Function
- **Path:** TX Sheet Control > API Reference > Formula Functions > TTEST Function
- **241 words**
- **Web URL:** https://docs.textcontrol.com/tx-sheet-control/reference/formula-functions/ttest/
- **LLMs URL:** https://docs.textcontrol.com/tx-sheet-control/reference/formula-functions/ttest/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-sheet-control/reference/formula-functions/ttest/llms-full.txt

---

Return the probability of a Student's t-test, which tells whether two samples are likely to come from populations with the same mean. TTEST is the compatibility version of [T.TEST](https://docs.textcontrol.com/tx-sheet-control/reference/formula-functions/t-test/llms-full.txt) and returns the same result. `tails` is 1 for a one-tailed or 2 for a two-tailed test; `type` is 1 for a paired test, 2 for equal variance or 3 for unequal variance. Another `tails` or `type` returns `#NUM!`.

### Syntax

```text
TTEST(array1, array2, tails, type)
```

Category: Statistics. Minimum arguments: 4. Maximum arguments: 4.

Available for supported offline calculation.

### Examples

```text
=TTEST({1,2,3},{2,4,6},2,2)
```

The formula returns 0.1962611781, the two-tailed probability of a test with equal variance.

Cell and range examples require appropriate input values in the referenced cells. Handle invalid arguments, formula errors and array and spill constraints.

### See Also

- [Formulas](https://docs.textcontrol.com/tx-sheet-control/spreadsheets/formulas/llms-full.txt)
- [Custom Functions and Formula Data](https://docs.textcontrol.com/tx-sheet-control/spreadsheets/custom-functions/llms-full.txt)

---

## Nearby

- **Previous:** [T.TEST Function](https://docs.textcontrol.com/tx-sheet-control/reference/formula-functions/t-test/llms-full.txt)
- **Next:** [TYPE Function](https://docs.textcontrol.com/tx-sheet-control/reference/formula-functions/type/llms-full.txt)
