Linear regression. How to calculate this problem

AI Thread Summary
The discussion centers on discrepancies in linear regression calculations between Excel and online calculators. The user initially calculated a linear equation but found differing results from Excel and another calculator. A key point revealed is that the user had mistakenly switched the X and Y data sets when inputting the values into the online calculator. After correcting the input order, the user confirmed that the results aligned with Excel's output. This highlights the importance of correctly identifying data sets in regression analysis.
Drudge
Messages
30
Reaction score
0

Homework Statement


Why does excel give me this:

http://postimg.org/image/68b9z1lqt/

And various online calulators (for example http://www.alcula.com/calculators/statistics/linear-regression/), and my own calulations give me this:

http://postimg.org/image/kpljm4awx/


Homework Equations



Raw data:

Y: 18.9, 31.9, 18.5, 33.9, 24.9, 15.2, 26.9, 26.9, 29.9, 29.9, 35.9, 21.9, 16.9, 8.9, 24.9

X: 5, 4, 3, 1, 4, 8, 3, 6, 7, 5, 3, 3, 9, 14, 4

The Attempt at a Solution



I get the linear equation of: y = -0.29967x + 12,5667

The book I am studying has the answer that you get from excel

Which one is right? Am I going insane or is there somwthing really wrong here?

 
Last edited by a moderator:
Physics news on Phys.org
Drudge - I plugged the numbers into your suggested application (from www.alcula.com) and I get the Excel results. It looks like you switched the x and y data sets. Enter the x values first, then the y values, and you should get the Excel results.
 
TheoMcCloskey said:
Drudge - I plugged the numbers into your suggested application (from www.alcula.com) and I get the Excel results. It looks like you switched the x and y data sets. Enter the x values first, then the y values, and you should get the Excel results.

O no! of course. thank you very much
 
I tried to combine those 2 formulas but it didn't work. I tried using another case where there are 2 red balls and 2 blue balls only so when combining the formula I got ##\frac{(4-1)!}{2!2!}=\frac{3}{2}## which does not make sense. Is there any formula to calculate cyclic permutation of identical objects or I have to do it by listing all the possibilities? Thanks
Back
Top