Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion lectures/five_preferences.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ We begin with some that we'll use to create some graphs.

```{code-cell} ipython3
# Package imports
import shutil
import numpy as np
import matplotlib as mpl
import matplotlib.pyplot as plt
Expand All @@ -67,7 +68,10 @@ from numba import njit
```{code-cell} ipython3
:tags: [hide-input]

plt.rc('text', usetex=True)
# Render text with LaTeX only where a latex binary exists (the build has
# texlive); on latex-less runtimes such as Colab, fall back to mathtext
# instead of raising at the first rendered figure.
plt.rc('text', usetex=bool(shutil.which('latex')))
plt.rc('font', size=18)
plt.rc('axes', labelsize=20, titlesize=24)
plt.rc('xtick', labelsize=18)
Expand Down
Loading