                                 (get-in activity-result [:round/panel :adjudicator-panel/adjudicators])))
             :dances (vec (map #(hash-map :name (:dance/name %))
                                 (get-in activity-result [:round/dances])))
-            :result-array (result-facts->result-array (:result/_activity activity-result))
-            }})
+            :result-array (result-facts->result-array (:result/_activity activity-result)
+                                                      (get-in activity-result
+                                                              [:round/panel
+                                                               :adjudicator-panel/adjudicators]))}})
+
+(def adjudicators
+  [{:adjudicator/number 1}
+   {:adjudicator/number 2}
+   {:adjudicator/number 3}
+   {:adjudicator/number 4}])
+
+(def result-facts
+  [{:result/mark-x true,
+    :result/adjudicator {:adjudicator/number 1},
+    :result/participant {:participant/number 143}}
+   {:result/mark-x true,
+    :result/adjudicator {:adjudicator/number 1},
+    :result/participant {:participant/number 141}}
+   {:result/mark-x false,
+    :result/adjudicator {:adjudicator/number 2},
+    :result/participant {:participant/number 141}}
+   {:result/mark-x false,
+    :result/adjudicator {:adjudicator/number 3},
+    :result/participant {:participant/number 141}}
+   {:result/mark-x true,
+    :result/adjudicator {:adjudicator/number 4},
+    :result/participant {:participant/number 141}}
+   {:result/mark-x true,
+    :result/adjudicator {:adjudicator/number 1},
+    :result/participant {:participant/number 144}}])
+
 
 ;; Provides useful Timbre aliases in this ns
 (log/refer-timbre)

    :result/adjudicator {:adjudicator/number 1},
    :result/participant {:participant/number 144}}])

(defn get-marks [result-facts]
  (vec (map #(:result/mark-x %) result-facts)))

(defn get-dancers [result-facts]
  (apply hash-set (map #(get-in % [:result/participant :participant/number]) result-facts)))


(defn get-results-for-dancer [result-facts dancer-number]
  (let [dancer-result-facts (filter
                             #(= dancer-number (get-in % [:result/participant :participant/number]))
                             result-facts)]
    {:dancer-number dancer-number
     :marks (get-marks dancer-result-facts)}))

(defn result-facts->result-array [result-facts]
  (let [dancer-numbers (get-dancers result-facts)]
    (vec (map #(get-results-for-dancer result-facts %) dancer-numbers ))))

(defn activity-result->class-result [activity-result]
  {:class-name (:activity/name activity-result)

    {:adjudicator/number 5}]},
  :round/dances [{:dance/name "Medium"} {:dance/name "Medium"}]}])

(defn activity-result [] (first (activities-with-result) ) )


(defn make-file-name-with-timestamp
