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

Skip to content

Commit 5c9c335

Browse files
timhoffmmeeseeksmachine
authored andcommitted
Backport PR #25797: Replace random values by hard-coded numbers in plot-types ...
1 parent 4ab1cb5 commit 5c9c335

File tree

3 files changed

+3
-6
lines changed

3 files changed

+3
-6
lines changed

plot_types/basic/bar.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,8 @@
1010
plt.style.use('_mpl-gallery')
1111

1212
# make data:
13-
np.random.seed(3)
1413
x = 0.5 + np.arange(8)
15-
y = np.random.uniform(2, 7, len(x))
14+
y = [4.8, 5.5, 3.5, 4.6, 6.5, 6.6, 2.6, 3.0]
1615

1716
# plot
1817
fig, ax = plt.subplots()

plot_types/basic/stem.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,8 @@
1111
plt.style.use('_mpl-gallery')
1212

1313
# make data
14-
np.random.seed(3)
1514
x = 0.5 + np.arange(8)
16-
y = np.random.uniform(2, 7, len(x))
15+
y = [4.8, 5.5, 3.5, 4.6, 6.5, 6.6, 2.6, 3.0]
1716

1817
# plot
1918
fig, ax = plt.subplots()

plot_types/basic/step.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,8 @@
1111
plt.style.use('_mpl-gallery')
1212

1313
# make data
14-
np.random.seed(3)
1514
x = 0.5 + np.arange(8)
16-
y = np.random.uniform(2, 7, len(x))
15+
y = [4.8, 5.5, 3.5, 4.6, 6.5, 6.6, 2.6, 3.0]
1716

1817
# plot
1918
fig, ax = plt.subplots()

0 commit comments

Comments
 (0)