renamed company to client.

This commit is contained in:
Bryce Covert
2019-01-18 07:44:12 -08:00
parent 583752d740
commit 775150131e
38 changed files with 250 additions and 306 deletions

View File

@@ -67,13 +67,12 @@
[file filename]
(excel/parse-file file filename))
(defn best-match [companies company-identifier]
(println companies)
(->> companies
(map (fn [company]
(if-let [matches (:matches company)]
[company (apply min (map #(m/jaccard (.toLowerCase company-identifier) %) matches))]
[company 1])))
(defn best-match [clients client-identifier]
(->> clients
(map (fn [client]
(if-let [matches (:client/matches client)]
[client (apply min (map #(m/jaccard (.toLowerCase client-identifier) %) matches))]
[client 1])))
(filter #(< (second %) 0.25))
(sort-by second)