# Bootstrapping the time until an event happens

Assume I have some measurements $$\{(y_i, t_i)\}^n_{i=1}$$, where $$y_i$$ is a real number (measured quantity) from some unknown random function $$y_i = f(x_i)$$, $$x_i$$ are inputs to that function and $$t_i$$ is the time needed to obtain the measurement (measuring time) associated with measurement $$i$$.

I want to characterize the black-box function $$f$$ by the time $$T$$ it takes to get a output larger than some threshold, i.e. $$y \geq \theta$$, when I naively evaluate $$f$$ on uniform random inputs. So $$T = \sum^m_{j=1} t_j$$, where $$y_m$$ is the first measurement exceeding my threshold.

Now I could make multiple runs, e.g. $$K$$, and average the $$T_k$$ to get the empirical mean estimator $$\bar{T} = \frac{1}{K} \sum_{k=1}^K T_k$$ and variance estimator.

However, measurements are costly and I want to minimize the number of measurements needed to get an estimate. Therefore I would like to use Bootstrapping. Can I apply the basic bootstrap algorithm in that case? Simply resampling with replacement from an initial set of measurements, calculating the time $$T$$ on each bootstrap sample.