0

Can you direct me to or provide an example that shows how to do a multiple linear regression analysis manually ?

I am very familiar with simple linear regression, and can perform a simple linear regression without the use of a statistics package. However I cannot do the same thing for multiple linear regression, and it is not for lack of Google searching. Most sources I have encountered end up with "And then do the multiple regression analysis in Minitab" (although it's definitely possible that some of them actually provided the method and I just didn't understand it)

In case I have the terminology wrong, when I say multiple linear regression, what I mean is 2 or more independent variables, with a single dependent variable. For instance, do a regression analysis to predict a person's heart attack risk based off their age and weight

Thank you!

Fairly Nerdy
  • 877
  • 1
  • 8
  • 16
  • 2
    It is actually the same method for simple and multiple linear regression, the difference being that beta and X are vector & scalar (simple) or matrice and vector (multiple). So you have $\beta = (X'X)^{-1}X'Y$, $\hat Y = X\beta$, $\varepsilon = Y - \hat Y$ and $H = X(X'X)^{-1}X'$ the "hat matrix". Reference can be found here: http://www.stat.purdue.edu/~jennings/stat514/stat512notes/topic3.pdf – Riff Feb 20 '17 at 07:39
  • 1
    Because multiple regression can be carried out as a [sequence of univariate regressions](http://stats.stackexchange.com/a/46508/919), you already have a way to do this. To be sure, such a sequence is not the most numerically stable method for large datasets--but you wouldn't be processing large amounts of data manually, anyway. – whuber Feb 20 '17 at 16:04

1 Answers1

1

Introduction to Linear Regression Analysis has an example in Example 3.1. Borrow yourself a copy from library.

SmallChess
  • 6,764
  • 4
  • 27
  • 48