Skip to content

Commit 78cb8c0

Browse files
committed
fix preamble for matplotlib v2
1 parent f8a5bf9 commit 78cb8c0

File tree

1 file changed

+4
-7
lines changed

1 file changed

+4
-7
lines changed

preamble.py

+4-7
Original file line numberDiff line numberDiff line change
@@ -5,23 +5,20 @@
55
import mglearn
66
from cycler import cycler
77

8-
#set_matplotlib_formats('png', 'svg')
98
set_matplotlib_formats('pdf', 'png')
109
plt.rcParams['savefig.dpi'] = 300
1110
plt.rcParams['image.cmap'] = "viridis"
1211
plt.rcParams['image.interpolation'] = "none"
1312
plt.rcParams['savefig.bbox'] = "tight"
1413
plt.rcParams['lines.linewidth'] = 2
1514
plt.rcParams['legend.numpoints'] = 1
16-
plt.rc('axes', prop_cycle=(cycler('color', mglearn.plot_helpers.cm_cycle.colors) +
17-
cycler('linestyle', ['-', '--', ':',
18-
'-.', '--'])
19-
)
20-
)
15+
plt.rc('axes', prop_cycle=(
16+
cycler('color', mglearn.plot_helpers.cm_cycle.colors) +
17+
cycler('linestyle', ['-', '-', "--", (0, (3, 3)), (0, (1.5, 1.5))])))
2118

2219
np.set_printoptions(precision=3, suppress=True)
2320

2421
pd.set_option("display.max_columns", 8)
2522
pd.set_option('precision', 2)
2623

27-
np, mglearn
24+
__all__ = ['np', 'mglearn', 'display', 'plt', 'pd']

0 commit comments

Comments
 (0)