Skip to content

Commit 0821641

Browse files
committed
update figure size to avoid overlaps
1 parent 19d2ec4 commit 0821641

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

lectures/markov_chains_II.md

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ jupytext:
44
extension: .md
55
format_name: myst
66
format_version: 0.13
7-
jupytext_version: 1.14.4
7+
jupytext_version: 1.16.1
88
kernelspec:
99
display_name: Python 3 (ipykernel)
1010
language: python
@@ -248,8 +248,6 @@ Hence we expect that $\hat p_n(x) \approx \psi^*(x)$ when $n$ is large.
248248
The next figure shows convergence of $\hat p_n(x)$ to $\psi^*(x)$ when $x=1$ and
249249
$X_0$ is either $0, 1$ or $2$.
250250

251-
252-
253251
```{code-cell} ipython3
254252
P = np.array([[0.971, 0.029, 0.000],
255253
[0.145, 0.778, 0.077],
@@ -312,7 +310,7 @@ P = np.array([[0, 1],
312310
ts_length = 10_000
313311
mc = qe.MarkovChain(P)
314312
n = len(P)
315-
fig, axes = plt.subplots(nrows=1, ncols=n)
313+
fig, axes = plt.subplots(figsize=(11, 5), nrows=1, ncols=n)
316314
ψ_star = mc.stationary_distributions[0]
317315
318316
for i in range(n):
@@ -395,8 +393,6 @@ ax.legend()
395393
plt.show()
396394
```
397395

398-
399-
400396
### Expectations of geometric sums
401397

402398
Sometimes we want to compute the mathematical expectation of a geometric sum, such as

0 commit comments

Comments
 (0)