code: def half_cauchy_like(x, alpha, beta):
      R
  
      x = np.atleast_1d(x)
      if sum(x.ravel() < 0):
          return -inf
      return flib.cauchy(x, alpha, beta) + len(x) * np.log(2)
docs: R"""
      Half-Cauchy log-likelihood. Simply the absolute value of Cauchy.
  
      .. math::
          f(x \mid \alpha, \beta) = \frac{2}{\pi \beta [1 + (\frac{x-\alpha}{\beta})^2]}
  
      :Parameters:
        - `alpha` : Location parameter.
        - `beta` : Scale parameter (beta > 0).
  
      .. note::
        - x must be non-negative.