code: def bayesianUpperLimit2(self, alpha, steps=1.e5, plot=False):
          
          cut = ((self.y / 2.) > -30.) # Numeric stability
          try:
              f = scipy.interpolate.interp1d(self.x[cut], self.y[cut], kind='cubic')
          except:
              f = scipy.interpolate.interp1d(self.x[cut], self.y[cut], kind='linear')
          x = np.linspace(0., np.max(self.x[cut]), steps)
          y = np.exp(f(x) / 2.)
          #forbidden = np.nonzero((y / np.exp(self.vertex_y / 2.)) < 1.e-10)[0]
          forbidden = np.nonzero((y / self.vertex_y) < 1.e-10)[0]
          if len(forbidden) > 0:
              index = forbidden[0] # Numeric stability
              x = x[0: index]
              y = y[0: index]
          cdf = np.cumsum(y)
          cdf /= cdf[-1]
          cdf_reflect = scipy.interpolate.interp1d(cdf, x)
  
          return cdf_reflect(alpha)
docs: Compute one-sided upper limit using Bayesian Method of Helene.