A Complete Introduction To Time Series Analysis (with R):: Prediction 1 → Best Predictors II

Hair Parra
Analytics Vidhya
Published in
4 min readJul 24, 2020

--

In the last article, we saw how we could obtain the best linear predictor (BLP) of X_{n+h} given a function of X_{n}. This week, we will see that the most appropriate model for this function has the form given above, by a series of manipulations. We will follow the same idea as before: minimize some objective function!

Best Linear Predictor of X_{n+h}

Why? Let’s see the derivation: we would like to find a model for

So we can consider a linear function, say

and then find a and b that minimizes the MSE, that is

Once again, we can take partials w.r.t a and b, obtaining the system

which we set to 0 for optimization purposes. Working this out a bit, this gives

so now we can solve for a, say. You can verify that the solution is given by

where we used “\mu” to represent the expectation as a function of the inner lag. Next, plugging back and solving for b, we obtain

so that

Does this look familiar? Recall that

So that the expression above becomes

Now, plugging this back once more into “a”, gives

--

--

Hair Parra
Analytics Vidhya

Data Scientist & Data Engineer. CS, Stats & Linguistics graduate. Polyglot.