<p>The <b>LINEST</b> function is one of the statistical functions. It is used to calculate the statistics for a line by using the least squares method to calculate a straight line that best fits your data, and then returns an array that describes the line; because this function returns an array of values, it must be entered as an array formula.</p>
<pstyle="text-indent: 50px;"><b><em>known_y's</em></b> is a known range of <em>y</em> values in the equation <em>y = mx + b</em>. This is the required argument.</p>
<pstyle="text-indent: 50px;"><b><em>known_x's</em></b> is a known range of <em>x</em> values in the equation <em>y = mx + b</em>. This is an optional argument. If it is omitted, <em>known_x's</em> is assumed to be the array <em>{1,2,3,...}</em> with the same number of values as <em>known_y's</em>.</p>
<pstyle="text-indent: 50px;"><b><em>const</em></b> is a logical value that specifies if you want to set <em>b</em> equal to <em>0</em>. This is an optional argument. If it is set to <em>TRUE</em> or omitted, <em>b</em> is calculated normally. If it is set to <em>FALSE</em>, <em>b</em> is set equal to <em>0</em>.</p>
<pstyle="text-indent: 50px;"><b><em>stats</em></b> is a logical value that specifies if you want to return additional regression statistics. This is an optional argument. If it is set to <em>TRUE</em>, the function returns the additional regression statistics. If it is set to <em>FALSE</em> or omitted, the function does not return the additional regression statistics.</p>
<p>To apply the <b>LINEST</b> function,</p>
<ol>
<li>select the cell where you wish to display the result,</li>