How to get the equation of a trend line in Calc? [closed] Suppose I have a (xy scatter) diagram in localc and insert a trend line, for example a linear one of the type f(x) = ax + b. I know hot to display the equation in the diagram, but how can I reference to the parameters a and b in a cell to make further calculations with it?

edit retag reopen merge delete

Closed for the following reason the question is answered, right answer was accepted by Alex Kemp close date 2016-03-04 23:56:25.817643

Oh, in ubuntu libreoffice calc can be started using the command localc

Sort by » oldest newest most voted @student - As you know how to display the trend line equation just look at the equation and take the parameters you need. The parameters have a high number of digits thus the result should be sufficiently precise.

Due to complexity reasons I feel the the equations @karolus indicates are only available for linear trend lines.

An enhancement request to copy the parameters from trend line equations appears to me as a very interesting one.

more

@ROSt52. I found a good solution to the problem link. I also filed a bug. To extract the trend line data from a series of x an y values, you can use the LINEST function. This function returns the values for s and b from your equation above. It can also return other tests such as the r squared value.

Because LINEST returns multiple results, it must be entered as an array formula. You do this by pressing Ctrl+Shift+Enter when you finish entering the formula. The results are returned to multiple cells. Approximately 2 columns wide by 5 rows high.

LINEST takes 4 arguments. 1 a list of Y-Values, 2 a list of x-values, 3 enter TRUE to force the vertical axis intercept to 0 or false for it to be calculated. 4. Enter TRUE to return regression statistics and FALSE to only return the values for a and b.

let us know if you have any questions.

Cheers,

John

more

A less-than-convenient workaround:

Copy the equation in the chart to clipboard.

Start a new OO Draw window: File > New > Drawing

Paste the equation

Select the equation and right-click > Break

Now you can click into the text and copy/paste it as plain text anywhere you like.

more