code: def abc(x, statistic=bs_se, alpha=0.05, eps=1e-5):
      """Calculate the bootstrap confidence interval by approximating the BCa.
  
      Parameters
      ----------
      x : np.ndarray
          Observed data (e.g. chosen gold standard estimate used for bootstrap)
      statistic : method
          Method to calculate the desired statistic given x and probability
          proportions (flat probability densities vector)
      alpha : float (0, 1)
          Desired confidence interval initial endpoint (Default: 0.05)
      eps : float (optional)
          Specifies step size in calculating numerical derivative T' and
          T''. Default: 1e-5
  
      See Also
      --------
      __tt, __tt_dot, __tt_dot_dot, __calc_z0
  
      Notes
      -----
      Unlike the BCa method of calculating the bootstrap confidence interval,
      the ABC method is computationally less demanding (about 3% computational
      power needed) and is fairly accurate (sometimes out performing BCa!). It
      does not require any bootstrap resampling and instead uses numerical
      derivatives via Taylor series to approximate the BCa calculation. However,
      the ABC method requires the statistic to be smooth and follow a
      multinomial distribution.
  
      References
      ----------
      ..  [2] DiCiccio, T.J., Efron, B., 1996. Bootstrap Confidence Intervals.
          Statistical Science. 11, 3, 189-228.
  
      """
      # define base variables -- n, p_0, sigma_hat, delta_hat
      n = len(x)
      p_0 = np.ones(x.shape) / n
      sigma_hat = np.zeros(x.shape)
      delta_hat = np.zeros(x.shape)
      for i in range(0, n):
          sigma_hat[i] = __tt_dot(i, x, p_0, statistic, eps) ** 2
          delta_hat[i] = __tt_dot(i, x, p_0, statistic, eps)
      sigma_hat = (sigma_hat / n**2) ** 0.5
      # estimate the bias (z_0) and the acceleration (a_hat)
      a_num = np.zeros(x.shape)
      a_dem = np.zeros(x.shape)
      for i in range(0, n):
          a_num[i] = __tt_dot(i, x, p_0, statistic, eps) ** 3
          a_dem[i] = __tt_dot(i, x, p_0, statistic, eps) ** 2
      a_hat = 1 / 6 * a_num / a_dem**1.5
      z_0 = __calc_z0(x, p_0, statistic, eps, a_hat, sigma_hat)
      # define helper variables -- w and l
      w = z_0 + __calc_z_alpha(1 - alpha)
      l = w / (1 - a_hat * w) ** 2
      return __tt(x, p_0 + l * delta_hat / sigma_hat, statistic)
  
file_path: dipy/dipy/boots/resampling.py
imports: import numpy
  import scipy
  import warnings
label_desc: Use image node_id 3 for calling a global function with example usage: abc(x, statistic, alpha, eps) and returns: __tt