docs: def posthoc_wilcoxon(a, val_col=None, group_col=None, zero_method='wilcox', correction=False, p_adjust=None, sort=False):
  
      '''Pairwise comparisons with Wilcoxon signed-rank test. It is a non-parametric
      version of the paired T-test for use with non-parametric ANOVA.
  
      Parameters
      ----------
      a : array_like or pandas DataFrame object
          An array, any object exposing the array interface or a pandas
          DataFrame. Array must be two-dimensional.
  
      val_col : str, optional
          Name of a DataFrame column that contains dependent variable values (test
          or response variable). Values should have a non-nominal scale. Must be
          specified if `a` is a pandas DataFrame object.
  
      group_col : str, optional
          Name of a DataFrame column that contains independent variable values
          (grouping or predictor variable). Values should have a nominal scale
          (categorical). Must be specified if `a` is a pandas DataFrame object.
  
      zero_method : string, {"pratt", "wilcox", "zsplit"}, optional
          "pratt": Pratt treatment, includes zero-differences in the ranking
          process (more conservative)
          "wilcox": Wilcox treatment, discards all zero-differences
          "zsplit": Zero rank split, just like Pratt, but spliting the zero rank
          between positive and negative ones
  
      correction : bool, optional
          If True, apply continuity correction by adjusting the Wilcoxon rank
          statistic by 0.5 towards the mean value when computing the z-statistic.
          Default is False.
  
      p_adjust : str, optional
          Method for adjusting p values.
          See statsmodels.sandbox.stats.multicomp for details.
          Available methods are:
          'bonferroni' : one-step correction
          'sidak' : one-step correction
          'holm-sidak' : step-down method using Sidak adjustments
          'holm' : step-down method using Bonferroni adjustments
          'simes-hochberg' : step-up method  (independent)
          'hommel' : closed method based on Simes tests (non-negative)
          'fdr_bh' : Benjamini/Hochberg  (non-negative)
          'fdr_by' : Benjamini/Yekutieli (negative)
          'fdr_tsbh' : two stage fdr correction (non-negative)
          'fdr_tsbky' : two stage fdr correction (non-negative)
  
      sort : bool, optional
          Specifies whether to sort DataFrame by group_col and val_col or not.
          Default is False.
  
      Returns
      -------
      result : pandas DataFrame
          P values.
  
      Notes
      -----
      Refer to `scipy.stats.wilcoxon` reference page for further details.
  
      Examples
      --------
      >>> x = [[1,2,3,4,5], [35,31,75,40,21], [10,6,9,6,1]]
      >>> sp.posthoc_wilcoxon(x)
  
      '''
  
      x, _val_col, _group_col = __convert_to_df(a, val_col, group_col)
  
      if not sort:
          x[_group_col] = Categorical(x[_group_col], categories=x[_group_col].unique(), ordered=True)
  
      #x.sort_values(by=[_group_col, _val_col], ascending=True, inplace=True)
      groups = np.unique(x[_group_col])
      x_len = groups.size
      vs = np.zeros((x_len, x_len))
      tri_upper = np.triu_indices(vs.shape[0], 1)
      tri_lower = np.tril_indices(vs.shape[0], -1)
      vs[:,:] = 0
  
      combs = it.combinations(range(x_len), 2)
  
      for i,j in combs:
          vs[i, j] = ss.wilcoxon(x.loc[x[_group_col] == groups[i], _val_col],
                                 x.loc[x[_group_col] == groups[j], _val_col],
                                 zero_method=zero_method, correction=correction)[1]
  
      if p_adjust:
          vs[tri_upper] = multipletests(vs[tri_upper], method=p_adjust)[1]
      vs[tri_lower] = vs.T[tri_lower]
      np.fill_diagonal(vs, -1)
      return DataFrame(vs, index=groups, columns=groups)