|
44 | 44 | # markevery with linear scales |
45 | 45 | # ---------------------------- |
46 | 46 |
|
47 | | -fig, axs = plt.subplots(3, 3, figsize=(10, 6), constrained_layout=True) |
| 47 | +fig, axs = plt.subplots(3, 3, figsize=(10, 6), layout='constrained') |
48 | 48 | for ax, markevery in zip(axs.flat, cases): |
49 | 49 | ax.set_title(f'markevery={markevery}') |
50 | 50 | ax.plot(x, y, 'o', ls='-', ms=4, markevery=markevery) |
|
58 | 58 | # fraction of figure size creates even distributions, because it's based on |
59 | 59 | # fractions of the Axes diagonal, not on data coordinates or data indices. |
60 | 60 |
|
61 | | -fig, axs = plt.subplots(3, 3, figsize=(10, 6), constrained_layout=True) |
| 61 | +fig, axs = plt.subplots(3, 3, figsize=(10, 6), layout='constrained') |
62 | 62 | for ax, markevery in zip(axs.flat, cases): |
63 | 63 | ax.set_title(f'markevery={markevery}') |
64 | 64 | ax.set_xscale('log') |
|
75 | 75 | # diagonal, it changes the displayed data range, and more points will be |
76 | 76 | # displayed when zooming. |
77 | 77 |
|
78 | | -fig, axs = plt.subplots(3, 3, figsize=(10, 6), constrained_layout=True) |
| 78 | +fig, axs = plt.subplots(3, 3, figsize=(10, 6), layout='constrained') |
79 | 79 | for ax, markevery in zip(axs.flat, cases): |
80 | 80 | ax.set_title(f'markevery={markevery}') |
81 | 81 | ax.plot(x, y, 'o', ls='-', ms=4, markevery=markevery) |
|
89 | 89 | r = np.linspace(0, 3.0, 200) |
90 | 90 | theta = 2 * np.pi * r |
91 | 91 |
|
92 | | -fig, axs = plt.subplots(3, 3, figsize=(10, 6), constrained_layout=True, |
| 92 | +fig, axs = plt.subplots(3, 3, figsize=(10, 6), layout='constrained', |
93 | 93 | subplot_kw={'projection': 'polar'}) |
94 | 94 | for ax, markevery in zip(axs.flat, cases): |
95 | 95 | ax.set_title(f'markevery={markevery}') |
|
0 commit comments