Linear regression with two dependent variables
Make excel linear regression with one independent variable is a snap with Excel 2007 or 2003. Since it can be done by using graphics that give us the straight linear fit equation, apart from other types of adjustments such as logarithmic, power, etc. Assuming a linear search, the type
y = f (x), y = mx + b. Myb values, indicating the constant and the line can be determined with LINEST function.
LINEST has the following syntax:
LINEST (valores_de_y; [valores_de_x], [ongoing] [statistics]) brackets are the parameters that are optional, we leave the third empty and statistical parameter type true. After selecting the cell below this, we press F2 and then CTRL + SHIFT + ENTER to do this we will have the values \u200b\u200bof m b.
If you have a correlation with two variables, y = a + b1 * x1 + b2 * x2. Excel can not calculate this equation directly, the values \u200b\u200bof a, b1 and b2 can be obtained by the following equations:
which could form the following system of equations:
Where it is possible to parameters a, b1, b2. To do this you can use Excel functions:
SUMPRODUCT (rango01; rango02) that the sum devulve between pairs of rango01 and rank 02.
.. SUM SQUARE (range) that returns the sum of squares of rank
With the use of these equations can calculate the values \u200b\u200bof the system of equations posed above. The next step is to invert the matrix of the left member, this can be done with the function:
MINVERSE (womb) which returns the inverse matrix. For this matrix must be square and with determinant different from zero. This function is used as follows, in a cell is written MINVERSE (rango_de_la_matriz), then from this cell select a range of 3x3, then finally press CTRL + F2 SHIFT + ENTER.
Then multiply the inverse matrix obtained on the right-column matrix, this is done similarly to the use MINVERSE is used for this case MMULT.
Here I leave a file so you can see the use of these functions. Download .
0 comments:
Post a Comment