anchor.diff:  
           iterate centroids [||]
   
  -    let distortionMetric (matrix: float[][]) (centroids: Vector[], clustering: int[]) : float = 
  +    let distortionMetric (matrix: Vector[]) (centroids: Vector[], clustering: int[]) : float = 
           matrix
           |> Array.mapi (fun i row -> distance row centroids.[clustering.[i]])
           |> Array.sum
   
  -    let resultMetric (size: int) (matrix: float[][]) (centroids: Vector[], clustering: int[]) =
  +    let resultMetric (size: int) (matrix: Vector[]) (centroids: Vector[], clustering: int[]) =
               let groups = clustering |> Seq.groupBy id
               let nGroups = groups |> Seq.length
               let nOverbooked = groups |> Seq.filter (fun g -> snd g |> Seq.length > size) |> Seq.length
  
positive.code:         if applyMetric then
              let nClusteringIterations = 200
  
              let results = [for i in 0..nClusteringIterations do yield matrix |> cluster 0 nGroups rng]
  
              let sortedResults = 
                  results 
                  |> orderByPopularity groupSize matrix
                  //|> List.sortBy (fun clustering -> clustering |> resultMetric groupSize matrix)                
                  |> Seq.take 10
                  |> List.ofSeq
  
              sortedResults 
              |> List.sortBy (fun clustering -> clustering |> resultMetric groupSize matrix)                
              |> Seq.head
              |> snd
  
                  (*
                  results
                  |> List.sortBy (fun clustering -> clustering |> resultMetric groupSize matrix)
                  |> Seq.take 20
  
              //|> Seq.head
              //|> snd
  
              sortedResults |> selectBestClustering groupSize matrix
              *)
          else
              snd (matrix |> cluster 0 nGroups rng)
  
  
negative.code:                 distortionMetric matrix (centroids, clustering) // out of those get whatever has smaller distortion
              )
  
      member this.computeGroups (dataSet: 'a array) (nGroups: int) =
          let input = dataSet |> Array.map featureExtractor
          let matrix = if shouldNormalize then normalize input else input
  