Skip to content

Commit 3c48fb0

Browse files
authored
[writing_good_code] Update figure size (#94)
1 parent d688ac4 commit 3c48fb0

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

lectures/writing_good_code.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -70,14 +70,15 @@ The plots will be grouped into three subfigures.
7070
In each subfigure, two parameters are held fixed while another varies
7171

7272
```{code-cell} ipython
73+
%matplotlib inline
7374
import numpy as np
7475
import matplotlib.pyplot as plt
75-
%matplotlib inline
76+
plt.rcParams['figure.figsize'] = (10,6)
7677
7778
# Allocate memory for time series
7879
k = np.empty(50)
7980
80-
fig, axes = plt.subplots(3, 1, figsize=(6, 14))
81+
fig, axes = plt.subplots(3, 1, figsize=(8, 16))
8182
8283
# Trajectories with different α
8384
δ = 0.1
@@ -267,7 +268,7 @@ def plot_path(ax, αs, s_vals, δs, time_series_length=50):
267268
ax.set_ylim(0, 18)
268269
ax.legend(loc='upper left', frameon=True)
269270
270-
fig, axes = plt.subplots(3, 1, figsize=(6, 14))
271+
fig, axes = plt.subplots(3, 1, figsize=(8, 16))
271272
272273
# Parameters (αs, s_vals, δs)
273274
set_one = ([0.25, 0.33, 0.45], [0.4], [0.1])

0 commit comments

Comments
 (0)