LINEST
parameters of the least-squares linear fit · from excel · excel: not yet compared · sheets: not yet compared
signature
LINEST(known_ys, [known_xs], [const], [stats])
returns: array
| argument | required |
|---|---|
| known_ys | required |
| known_xs | optional |
| const | optional |
| stats | optional · defaults to 0 |
examples
formula and result, taken from the engine's own test suite — every result below is asserted in CI, not written by hand.
| A | |
|---|---|
| 1 | 10 |
| 2 | 20 |
| 3 | 30 |
| 4 | 40 |
| 5 | 50 |
fx
=LINEST(A1:A10) -3.3333333333333335 errors
error values observed from the engine — each with a call that produces it.
| error | produced by |
|---|---|
| #VALUE! | =LINEST(2) |
related
- AVEDEV average of absolute deviations from the mean
- AVERAGE.WEIGHTED average of values weighted by a second range
- AVERAGEA averages values including text and logicals
- AVERAGEIF averages cells that match a condition
- AVERAGEIFS averages cells matching multiple conditions
- BETA.DIST beta distribution