docs: def common_mean_watson(Data1, Data2, NumSims=5000, print_result=True, plot='no', save=False, save_folder='.', fmt='svg'):
      """
      Conduct a Watson V test for a common mean on two directional data sets.
  
      This function calculates Watson's V statistic from input files through
      Monte Carlo simulation in order to test whether two populations of
      directional data could have been drawn from a common mean. The critical
      angle between the two sample mean directions and the corresponding
      McFadden and McElhinny (1990) classification is printed.
  
      Parameters
      ----------
      Data1 : a nested list of directional data [dec,inc] (a di_block)
      Data2 : a nested list of directional data [dec,inc] (a di_block)
      NumSims : number of Monte Carlo simulations (default is 5000)
      print_result : default is to print the test result (True)
      plot : the default is no plot ('no'). Putting 'yes' will the plot the CDF
          from the Monte Carlo simulations.
      save : optional save of plots (default is False)
      save_folder : path to where plots will be saved (default is current)
      fmt : format of figures to be saved (default is 'svg')
  
      Returns
      -------
      printed text : text describing the test result is printed
      result : a boolean where 0 is fail and 1 is pass
      angle : angle between the Fisher means of the two data sets
      critical_angle : critical angle for the test to pass
  
      Examples
      --------
      Develop two populations of directions using ``ipmag.fishrot``. Use the
      function to determine if they share a common mean.
  
      >>> directions_A = ipmag.fishrot(k=20, n=30, dec=40, inc=60)
      >>> directions_B = ipmag.fishrot(k=35, n=25, dec=42, inc=57)
      >>> ipmag.common_mean_watson(directions_A, directions_B)
      """
      pars_1 = pmag.fisher_mean(Data1)
      pars_2 = pmag.fisher_mean(Data2)
      cart_1 = pmag.dir2cart([pars_1["dec"], pars_1["inc"], pars_1["r"]])
      cart_2 = pmag.dir2cart([pars_2['dec'], pars_2['inc'], pars_2["r"]])
      Sw = pars_1['k'] * pars_1['r'] + pars_2['k'] * pars_2['r']  # k1*r1+k2*r2
      xhat_1 = pars_1['k'] * cart_1[0] + pars_2['k'] * cart_2[0]  # k1*x1+k2*x2
      xhat_2 = pars_1['k'] * cart_1[1] + pars_2['k'] * cart_2[1]  # k1*y1+k2*y2
      xhat_3 = pars_1['k'] * cart_1[2] + pars_2['k'] * cart_2[2]  # k1*z1+k2*z2
      Rw = np.sqrt(xhat_1**2 + xhat_2**2 + xhat_3**2)
      V = 2 * (Sw - Rw)
      # keep weighted sum for later when determining the "critical angle"
      # let's save it as Sr (notation of McFadden and McElhinny, 1990)
      Sr = Sw
  
      # do monte carlo simulation of datasets with same kappas as data,
      # but a common mean
      counter = 0
      Vp = []  # set of Vs from simulations
      for k in range(NumSims):
  
          # get a set of N1 fisher distributed vectors with k1,
          # calculate fisher stats
          Dirp = []
          for i in range(pars_1["n"]):
              Dirp.append(pmag.fshdev(pars_1["k"]))
          pars_p1 = pmag.fisher_mean(Dirp)
      # get a set of N2 fisher distributed vectors with k2,
      # calculate fisher stats
          Dirp = []
          for i in range(pars_2["n"]):
              Dirp.append(pmag.fshdev(pars_2["k"]))
          pars_p2 = pmag.fisher_mean(Dirp)
      # get the V for these
          Vk = pmag.vfunc(pars_p1, pars_p2)
          Vp.append(Vk)
  
      # sort the Vs, get Vcrit (95th percentile one)
  
      Vp.sort()
      k = int(.95 * NumSims)
      Vcrit = Vp[k]
  
      # equation 18 of McFadden and McElhinny, 1990 calculates the critical
      # value of R (Rwc)
  
      Rwc = Sr - (old_div(Vcrit, 2))
  
      # following equation 19 of McFadden and McElhinny (1990) the critical
      # angle is calculated. If the observed angle (also calculated below)
      # between the data set means exceeds the critical angle the hypothesis
      # of a common mean direction may be rejected at the 95% confidence
      # level. The critical angle is simply a different way to present
      # Watson's V parameter so it makes sense to use the Watson V parameter
      # in comparison with the critical value of V for considering the test
      # results. What calculating the critical angle allows for is the
      # classification of McFadden and McElhinny (1990) to be made
      # for data sets that are consistent with sharing a common mean.
  
      k1 = pars_1['k']
      k2 = pars_2['k']
      R1 = pars_1['r']
      R2 = pars_2['r']
      critical_angle = np.degrees(np.arccos(old_div(((Rwc**2) - ((k1 * R1)**2)
                                                     - ((k2 * R2)**2)),
                                                    (2 * k1 * R1 * k2 * R2))))
      D1 = (pars_1['dec'], pars_1['inc'])
      D2 = (pars_2['dec'], pars_2['inc'])
      angle = pmag.angle(D1, D2)
  
      if print_result == True:
          print("Results of Watson V test: ")
          print("")
          print("Watson's V:           " '%.1f' % (V))
          print("Critical value of V:  " '%.1f' % (Vcrit))
  
      if V < Vcrit:
          if print_result == True:
              print('"Pass": Since V is less than Vcrit, the null hypothesis')
              print('that the two populations are drawn from distributions')
              print('that share a common mean direction can not be rejected.')
          result = 1
      elif V > Vcrit:
          if print_result == True:
              print('"Fail": Since V is greater than Vcrit, the two means can')
              print('be distinguished at the 95% confidence level.')
          result = 0
  
      if print_result == True:
          print("")
          print("M&M1990 classification:")
          print("")
          print("Angle between data set means: " '%.1f' % (angle))
          print("Critical angle for M&M1990:   " '%.1f' % (critical_angle))
  
      if print_result == True:
          if V > Vcrit:
              print("")
          elif V < Vcrit:
              if critical_angle < 5:
                  print("The McFadden and McElhinny (1990) classification for")
                  print("this test is: 'A'")
              elif critical_angle < 10:
                  print("The McFadden and McElhinny (1990) classification for")
                  print("this test is: 'B'")
              elif critical_angle < 20:
                  print("The McFadden and McElhinny (1990) classification for")
                  print("this test is: 'C'")
              else:
                  print("The McFadden and McElhinny (1990) classification for")
                  print("this test is: 'INDETERMINATE;")
  
      if plot == 'yes':
          CDF = {'cdf': 1}
          # pmagplotlib.plot_init(CDF['cdf'],5,5)
          plt.figure(figsize=(3.5, 2.5))
          p1 = pmagplotlib.plot_cdf(CDF['cdf'], Vp, "Watson's V", 'r', "")
          p2 = pmagplotlib.plot_vs(CDF['cdf'], [V], 'g', '-')
          p3 = pmagplotlib.plot_vs(CDF['cdf'], [Vp[k]], 'b', '--')
          # pmagplotlib.draw_figs(CDF)
          if save == True:
              plt.savefig(os.path.join(
                  save_folder, 'common_mean_watson') + '.' + fmt)
          pmagplotlib.show_fig(CDF['cdf'])
  
      return result, angle[0], critical_angle