code: public double[][] transform(double[][] x) {
          double[][] y = new double[x.length][];
          for (int i = 0; i < y.length; i++) {
              y[i] = transform(x[i]);
          }
  
          return y;
      }
docs: Transform an array of feature vectors.
  @param x an array of feature vectors. The feature
  vectors may be modified on output if copy is false.
  @return the transformed feature vectors.