Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit f6110d5

Browse files
committed
Minor fix
1 parent a9a60a6 commit f6110d5

File tree

3 files changed

+9
-8
lines changed

3 files changed

+9
-8
lines changed

doc/users/next_whats_new/histogram_vectorized_parameters.rst

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,10 @@ be achieved by passing a list of colors to the ``color`` parameter.
1111
.. plot::
1212
:include-source: true
1313
:alt: Three charts, identified as ax1, ax2 and ax3, show a stacking of three
14-
histograms representing Poisson distributions. The histograms in ax1, ax2, and ax3
15-
are differentiated by linewidths, hatches and linestyles, respectively. In ax1, ax2
16-
and ax3, each histogram is bordered by a different color.
14+
histograms representing Poisson distributions. The histograms in ax1, ax2,
15+
and ax3 are differentiated by linewidths, hatches and linestyles,
16+
respectively. In ax1, ax2 and ax3, each histogram is bordered by a different
17+
color.
1718

1819
import matplotlib.pyplot as plt
1920
import numpy as np

galleries/examples/statistics/histogram_multihist.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@
108108

109109
# %%
110110
# Histograms with LineStyles
111-
# ...........................
111+
# ..........................
112112

113113
fig, ax = plt.subplots()
114114

lib/matplotlib/axes/_axes.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7214,18 +7214,18 @@ def hist(self, x, bins=None, range=None, density=False, weights=None,
72147214
# cast each element to str, but keep a single str as it.
72157215
labels = [] if label is None else np.atleast_1d(np.asarray(label, str))
72167216

7217-
cyc = mpl.rcParams['axes.prop_cycle'].by_key()['color']
7218-
72197217
hatches = itertools.cycle(np.atleast_1d(kwargs.get('hatch', None)))
72207218
if histtype.startswith('bar') or histtype == 'stepfilled':
72217219
edgecolors = itertools.cycle(np.atleast_1d(kwargs.get('edgecolor', None)))
72227220
else:
7223-
edgecolors = itertools.cycle(np.atleast_1d(kwargs.get('edgecolor', cyc)))
7221+
edgecolors = itertools.cycle(np.atleast_1d(kwargs.get('edgecolor',
7222+
colors)))
72247223
if histtype.startswith('bar'):
72257224
facecolors = itertools.cycle(np.atleast_1d(kwargs.get('facecolor',
72267225
colors)))
72277226
else:
7228-
facecolors = itertools.cycle(np.atleast_1d(kwargs.get('facecolor', cyc)))
7227+
facecolors = itertools.cycle(np.atleast_1d(kwargs.get('facecolor',
7228+
colors)))
72297229
linewidths = itertools.cycle(np.atleast_1d(kwargs.get('linewidth', None)))
72307230
linestyles = itertools.cycle(np.atleast_1d(kwargs.get('linestyle', None)))
72317231

0 commit comments

Comments
 (0)