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

Skip to content

Commit c4dee7a

Browse files
NelleVQuLogic
authored andcommitted
Merge pull request #7868 from phobson/fix-boxplot-bootstrapper
MNT: reference the proper variable in bootstrapper
1 parent 2262d53 commit c4dee7a

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

lib/matplotlib/cbook.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1965,8 +1965,8 @@ def _bootstrap_median(data, N=5000):
19651965
M = len(data)
19661966
percentiles = [2.5, 97.5]
19671967

1968-
ii = np.random.randint(M, size=(N, M))
1969-
bsData = x[ii]
1968+
bs_index = np.random.randint(M, size=(N, M))
1969+
bsData = data[bs_index]
19701970
estimate = np.median(bsData, axis=1, overwrite_input=True)
19711971

19721972
CI = np.percentile(estimate, percentiles)

0 commit comments

Comments
 (0)