     (for [rep cluster-reps]
       [(metric pt rep), rep])))
 
-;;;
+
+;;; "Constants"
+
+;; TODO: find optimal subdivision for r/fold (partition-size)
+
+(def memoized-dbscan
+  "If true, calls to the metric passed to dbscan will be memoized"
+  true)
+
+(def memoized-medioids
+  "If true, calls to the metric passed to medioid-protein will be memoized"
+  true)
+
+(def region-query
+  "Select region-query-s (serial) or region-query-p (parallel)"
+  region-query-p)
+
+(def partition-size
+  "Approximate subdivision size for clojure.core.reducers/fold"
+  16)
+
+;;; Evaluation
 
 (def files
   ["UniRef90_A0A060TYH3.fa", "UniRef90_I0C6W8.fa","UniRef90_Q0A457.fa",

(region-query [0 0] pts r2-dist 2)
  
(map #(region-query % pts r2-dist 1) '([0 0] [0 1]))
)


(defn medioid
  "Return element of cluster that maximizes sum of similarity scores" 
  [cluster metric]
  (let [mem-metric (if memoized-medioids
                     (memoize-metric metric)
                      metric)]
    (second 
