Linear Regression
- You might also want to see how two variables are correlated.
- For instance, you want to see if age is correlated to education.
- This means your input is with pairs of data (age education).
- In my case the pair is 43-22 meaning I'm 43 and I've had 22 years
of school.
- The formula for corrlelation is r = (N* sum(xy)-(sum(x)*sum(y)))/
sqrt[(N(sum(x*x))- (sum (x))^2)][N(sum (y*y))-(sum(y))^2]
- Let me expand it.
- Though I can program it, I don't really feel how it works.
- I find that plugging through some examples helps.
- However, in this case, I don't want to plug through an example.
- I slammed in some data into Excel, used slope and intercept and
got the line.