(data, N=5000)
| 1230 | """ |
| 1231 | |
| 1232 | def _bootstrap_median(data, N=5000): |
| 1233 | # determine 95% confidence intervals of the median |
| 1234 | M = len(data) |
| 1235 | percentiles = [2.5, 97.5] |
| 1236 | |
| 1237 | bs_index = np.random.randint(M, size=(N, M)) |
| 1238 | bsData = data[bs_index] |
| 1239 | estimate = np.median(bsData, axis=1, overwrite_input=True) |
| 1240 | |
| 1241 | CI = np.percentile(estimate, percentiles) |
| 1242 | return CI |
| 1243 | |
| 1244 | def _compute_conf_interval(data, med, iqr, bootstrap): |
| 1245 | if bootstrap is not None: |
no outgoing calls
no test coverage detected
searching dependent graphs…