# LOGEST Function

> Fit the exponential curve y = b·m^x to data with LOGEST in TX Sheet Control: known_y, known_x, const, stats, spilled arrays and the #NUM! error.

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

---

Return the statistics of the exponential curve that best fits the data, y = b·mˣ. `known_y` holds the dependent values, which must be greater than 0, and `known_x` the independent ones (1, 2, 3 and so on when omitted). `const` TRUE or omitted calculates `b` and FALSE sets it to 1, and `stats` TRUE adds rows of regression statistics. The result is an array that spills, with `m` first and `b` second; a `known_y` value of 0 or less returns `#NUM!`.

### Syntax

```text
LOGEST(known_y, known_x, const, stats)
```

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

Available for supported offline calculation.

### Examples

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

The formula returns m = 1.7320508076 and b = 1.2114137286 in two cells of a row, the exponential curve closest to the values 2, 4 and 6.

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:** [LOG10 Function](https://docs.textcontrol.com/tx-sheet-control/reference/formula-functions/log10/llms-full.txt)
- **Next:** [LOGINV Function](https://docs.textcontrol.com/tx-sheet-control/reference/formula-functions/loginv/llms-full.txt)
