AR model with a driving/source term


Is there a way to include a source term in an AR1 model?

x(n+1) = rho_1 x(n) + y(n), where y(n) is the driving term/array that is known a-priori.



Depends, if the AR is latent, you can add the y(n) to the RV AR += y. If the AR is observed, you can do observed=data-y


Awesome. Thanks !!


Actually, I think that adding y to x is not the same as adding a drive to the AR1 model. Consider the recurrence:

x(n+1) = \rho_1 x(n) + y(n) = \rho_1 (\rho_1 x(n-1) + y(n-1)) + y(n)
x(n+1) = \rho_1^{2} x(n-1) + \rho_1 y(n-1) + y(n)

If you had the process \tilde{x} with no driving term:
\tilde{x}(n+1) = \rho_1 \tilde{x}(n) = \rho_1^{2}\tilde{x}(n-1)

Then \tilde{x}(n+1) + y(n) = \rho_1 \tilde{x}(n) + y(n) = \rho_1^{2}\tilde{x}(n-1) + y(n)\neq x(n+1) because you don’t get the recurrent \rho_1 y(n-...) terms.

I suggest you use the AR distribution instead of the AR1, because it allows you to add in the driving term \rho_0.


You are right, good point.