code: public double getPValue(final String method) {
          double p = Double.NaN;
  
          if ("t".equals(method)) {
              double[] baselineValues = new double[baselineMetricPerDimension.values().size()];
              int i = 0;
              for (Double d : baselineMetricPerDimension.values()) {
                  baselineValues[i] = d;
                  i++;
              }
  
              double[] testValues = new double[testMetricPerDimension.values().size()];
              i = 0;
              for (Double d : testMetricPerDimension.values()) {
                  testValues[i] = d;
                  i++;
              }
  
              p = TestUtils.tTest(baselineValues, testValues);
          } else {
              double[] baselineValues = new double[dimensions.size()];
              int i = 0;
              for (Object d : dimensions) {
                  baselineValues[i] = baselineMetricPerDimension.get(d);
                  i++;
              }
  
              double[] testValues = new double[dimensions.size()];
              i = 0;
              for (Object d : dimensions) {
                  testValues[i] = testMetricPerDimension.get(d);
                  i++;
              }
              if ("pairedT".equals(method)) {
                  p = TestUtils.pairedTTest(baselineValues, testValues);
              } else if ("wilcoxon".equals(method)) {
                  p = new WilcoxonSignedRankTest().wilcoxonSignedRankTest(baselineValues, testValues, false);
              }
          }
          return p;
      }
docs: Gets the p-value according to the requested method.
  
  @param method one of "t", "pairedT", "wilcoxon"
  @return the p-value according to the requested method