Last time | Next time |
Any time that the model is linear in the parameters, then we can use simple linear regression to find a "best-fit" (using the criterion of least sum of squared residuals).
So it turns out that we can use linear regression to find the best parameters of this quadratic "nonlinear model" to the Keeling data, and we'll do that today.
we can consider a model \[ CO_2(t)=a+bt+ct^2+d\sin(\alpha t)+e\cos(\beta t) \] which is linear in $a$, $b$, $c$, $d$, $e$, but non-linear in $\alpha$ and $\beta$. But those greek parameters determine the periodicity of the trig functions, which we have already decided is one year -- so we know those! Hence we can use linear regression to fit this model: \[ CO_2(t)=a+bt+ct^2+d\sin(2 \pi t)+e\cos(2 \pi t) \] to this "refined" Keeling data. In fact, this is a graph of monthly averages. We can obtain the daily (and even hourly!) Keeling data, if we wish.
And we will be able to fit some models non-linear in the parameters using these methods as well, via either
Alexander also illustrates that one cannot simply invert the regression equation $y=a+bx$ to get the regression equation $x=\frac{y-a}{b}$. So it really matters in linear regression which variable is considered "independent" and which is considered "dependent".