Column order in regression analysis

Marte Jørgensen shared this problem 2 years ago


I discovered a bug in regression analysis today. If I analyse the series 1, 2, 3, 4 in column A and 4, 9, 16, 25 in column B through 2. degree polynomial regression, I get what I expect: y = x^2 + 2x + 1.

However, if the series are placed in not adjacent columns, e.g. A and C, the default is for some reason that the series I mark first is defined as the y values, and the second as x-values. The resulting function is y = -0.0029x^2+0.2257x+0.1622. In this case, I can easily see the mistake, but often it's harder to predict.

© 2022 International GeoGebra Institute