code: def hdmedian(data, axis=-1, var=False):
      """
      Returns the Harrell-Davis estimate of the median along the given axis.
  
      Parameters
      ----------
      data : ndarray
          Data array.
      axis : int, optional
          Axis along which to compute the quantiles. If None, use a flattened
          array.
      var : bool, optional
          Whether to return the variance of the estimate.
  
      Returns
      -------
      hdmedian : MaskedArray
          The median values.  If ``var=True``, the variance is returned inside
          the masked array.  E.g. for a 1-D array the shape change from (1,) to
          (2,).
  
      """
      result = hdquantiles(data, [0.5], axis=axis, var=var)
      return result.squeeze()
  
file_path: catboost/contrib/python/scipy/py2/scipy/stats/mstats_extras.py
imports: from __future__ import division, print_function, absolute_import
  import numpy
  from numpy import float_, int_, ndarray
  import numpy.ma
  from numpy.ma import MaskedArray
  from .None import mstats_basic
  from scipy.stats.distributions import norm, beta, t, binom
label_desc: Use image node_id 2 for calling a global function with example usage: hdmedian(data, axis, var) and returns: result