Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

changed ar1 logp to use ar1 precision instead of innovation precision #3899

Merged
merged 13 commits into from
Jun 11, 2020
5 changes: 3 additions & 2 deletions pymc3/distributions/timeseries.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,11 +69,12 @@ def logp(self, x):
TensorVariable
"""
k = self.k
tau_e = self.tau_e
tau_e = self.tau_e #innovation precision
ljmartin marked this conversation as resolved.
Show resolved Hide resolved
tau = self.tau #ar1 precision

x_im1 = x[:-1]
x_i = x[1:]
boundary = Normal.dist(0., tau=tau_e).logp
boundary = Normal.dist(0., tau=tau).logp

innov_like = Normal.dist(k * x_im1, tau=tau_e).logp(x_i)
return boundary(x[0]) + tt.sum(innov_like)
Expand Down