Skip to content

Commit d899159

Browse files
committed
DOC: remove redundant gridspec from example
1 parent 9130caf commit d899159

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

galleries/examples/lines_bars_and_markers/scatter_hist.py

+3-4
Original file line numberDiff line numberDiff line change
@@ -90,11 +90,10 @@ def scatter_hist(x, y, ax, ax_histx, ax_histy):
9090

9191
# Create a Figure, which doesn't have to be square.
9292
fig = plt.figure(layout='constrained')
93-
# Create the main Axes, leaving 25% of the figure space at the top and on the
94-
# right to position marginals.
95-
ax = fig.add_gridspec(top=0.75, right=0.75).subplots()
93+
# Create the main Axes.
94+
ax = fig.add_subplot()
9695
# The main Axes' aspect can be fixed.
97-
ax.set(aspect=1)
96+
ax.set_aspect('equal')
9897
# Create marginal Axes, which have 25% of the size of the main Axes. Note that
9998
# the inset Axes are positioned *outside* (on the right and the top) of the
10099
# main Axes, by specifying axes coordinates greater than 1. Axes coordinates

0 commit comments

Comments
 (0)