 (ns bench.core
   (:require [kdtree.core :as k]
+            [intervaltree.core :as it]
             [cljs.pprint :refer (pprint)]
             [cljs.nodejs :as node]))
 

    (= type "test")
    (test-accuracity)

    :else
    (println "not implemented")))


    (pprint (js->clj (.nearest tree #js [1742 1420] 6)))
    ))

(defn test-interval
  []
  (let [tree (doto (it/create)
               (.add #js [1 5])
               (.add #js [5 7])
               (.add #js [-4 -1])
               (.add #js [-10 -3])
               (.add #js [-20 -10])
               (.add #js [20 30])
               (.add #js [3 9])
               (.add #js [100 200])
               (.add #js [1000 2000])
               (.add #js [6 9])
               )]
    (js/console.dir tree #js {"depth" nil})
    (js/console.log "contains", 4, (.contains tree 4))
    (js/console.log "contains", 0, (.contains tree 0))
    ))

(defn main
  [& [type]]
  (cond
