Skip to content

Commit

Permalink
small change on the printing of the decision rules
Browse files Browse the repository at this point in the history
  • Loading branch information
HumphreyYang committed Jul 21, 2024
1 parent 760582b commit 29261ab
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions lectures/calvo_machine_learn.md
Original file line number Diff line number Diff line change
Expand Up @@ -1218,17 +1218,17 @@ clq = ChangLQ(β=0.85, c=2, T=T)
Now let's print out the decision rule for $\mu_t$ uncovered by applying dynamic programming squared.
```{code-cell} ipython3
print("decision rule for mu")
print("-(b_0, b_1) = ", -clq.b0, -clq.b1)
print("decision rule for μ")
print(f'-(b_0, b_1) = ({-clq.b0:.6f}, {-clq.b1:.6f})')
```
Now let's print out the decision rule for $\theta_{t+1} $ uncovered by applying dynamic programming squared.
```{code-cell} ipython3
print("decision rule for theta(t+1) as function of theta(t)")
print("(d_0, d_1) = ", clq.d0, clq.d1)
print("decision rule for θ(t+1) as function of θ(t)")
print(f'(d_0, d_1) = ({clq.d0:.6f}, {clq.d1:.6f})')
```
Evidently, these agree with the relationships that we discovered by running regressions on the Ramsey outcomes $\vec \mu^R, \vec \theta^R$ that we constructed with either of our machine learning algorithms.
We have set the stage for diving into this quantecon lecture {doc}`calvo`.

1 comment on commit 29261ab

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.