   "Dist matrix"
   ([m] (dist-matrix m m))
   ([m1 m2]
-   (matrix
+   (matrix/matrix
      (map
        (fn [r1]
          (map

(defn kmeans
  "Performs a k-means clustering."
  [data k & {:keys [last-clusters max-iters weights] :or {max-iters 20}}]
  (let [data-iter (zip (nm/rownames data) (matrix (nm/get-matrix data)))
        clusters  (if last-clusters
                    (clean-start-clusters data last-clusters k :weights weights)
                    (init-clusters data k))]

              (pc/fn->> :members (map trans) set)
              clsts)
   :center (map
             (pc/fn->> :center (mapv #(utils/round-to % 4)))
             clsts)})


