docs: public static int medoid(boolean parallel, Collection<Integer> indecies, List<? extends Vec> X, DistanceMetric dm, List<Double> accel)
      {
          double bestDist = Double.POSITIVE_INFINITY;
          int bestIndex = -1;
          for (int i : indecies)
          {
              double thisCandidateDistance;
              final int medCandadate = i;
  
              thisCandidateDistance = ParallelUtils.range(indecies.size(), parallel)
                      .filter(j -> j != i)
                      .mapToDouble(j -> dm.dist(medCandadate, j, X, accel))
                      .sum();
  
              if (thisCandidateDistance < bestDist)
              {
                  bestIndex = i;
                  bestDist = thisCandidateDistance;
              }
          }
          
          return bestIndex;
      }