Is there a way to copy a trendline equation into a cell? I always re-type the equation from the chart into the cell.
Is there a way to copy a trendline equation into a cell? I always re-type the equation from the chart into the cell.
You can select the trendline label -> copy -> select cell -> paste to put the formula text into a cell. Of course, that is still just a useless text string.
Because all of the build in trendline options are linear (or can be transformed to be linear), I prefer to perform regressions directly in the spreadsheet using the LINEST() function: https://support.office.com/en-us/art...a-fa7abf772b6d Will that be an acceptable option?
Originally Posted by shg
The problem is that the cut and paste or copy and paste feature does not work when trying to copy a formula from the chart. Otherwise, I would at least get the coefficients easily inserted into a cell and would only have to modify the variables, exponents, and include some multiplication signs. Still a pain, but I can't get anything to copy now.
I would like to be able to easily create a column of formula-generated values along side the raw date values. I always have to re-invent the wheel each time by manually typing the equations.
I am not sure why you cannot copy anything from the trendline label to the spreadsheet. This is not a problem I run into, because I don't use the chart trendline to perform regressions. I use the LINEST() function and perform the regression in the spreadsheet. Are you required to use the chart trendline to perform the regression? Are you open to learning how to use the LINEST() function?
I am open to LINEST(), but sometimes I want a quadratic or other function. I just spent a minute playing around with LINEST() and see that it gave me the slope right away. I didn't spend time to find the y-int. I will play around with it some more, but I still would like to be able to grab the equations off the chart.
The help file I linked to above includes an example for a cubic polynomial. Other polynomials (including quadratics) should be straightforward.
I'm not sure why it did not give you the y-int. LINEST() is supposed to output a horizontal array with all of the "slopes" and the y-intercept in one array. If it only gave you the slope, that suggests that you only selected one cell when you entered the function -- be sure you are selecting the entire output array when you array enter the LINEST() function.
If you are committed to copying equations off of the chart -- I guess the first thing is to figure out why it won't let you copy-paste the formula text into a cell. I have never had real trouble with that part. Once we get the text string to paste into a cell, we should be able to put the text manipulation functions together that will extract the coefficients from the text string.
I had the same issue with copying the formula out.
What worked for me was changing the format of the formula to number. In my version it asked how many decimal places you wanted so I added a bunch
just to make sure my formula was accurate then copied it.
You have to do a little bit of clean up.
Remove the "y" from the beginning of the formula.
The formula does not include the multiplication sign so "*" will need to be added.
and you need to add "^" for values that are squared etc.
I'm sure there are others but that was as complicated as my formulas got.
Hope that helps.
If I'm working with a simple Linear equation, I always use the SLOPE and INTERSEPT functions to pull those out into a separate cell
=SLOPE(y values, x values)
=INTERSEPT(y values, x values)
and then reference those cells.
ChemistB
My 2?
substitute commas with semi-colons if your region settings requires
Don't forget to mark threads as "Solved" (Edit First post>Advanced>Change Prefix)
If I helped, Don't forget to add to my reputation (click on the little star at bottom of this post)
Forum Rules: How to use code tags, mark a thread solved, and keep yourself out of trouble
My method is:
-Try to copy the trendline equation by pressing CTRL+C 5 times.
-Try to paste into Word
-Fail
-Return to Excel
-Copy the equation by pressing CTRL+5 times
-Go to Word
-Paste successfully.
The aforementioned works every time, though I'm not sure what makes it work. It just does.
It's a lot faster than tinkering with the formatting or writing the equation over, at least.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks