                     (om/set-state! owner :sy (+ sy dy))
                     ))
            (log/warning l "nothing!"))
-         (recur (alts! [down up move])))
-       )
-     (let [{:keys [ws-chan select-chan event-bus]} (om/get-shared owner)
-           e-chan (chan)
-           ws-sub-chan (chan (sliding-buffer 25))]
-       (async/tap (:bus event-bus) e-chan)
-       (sub (:pub ws-chan) :post ws-sub-chan)
-       (go-loop
-           [[m c] (alts! [ws-sub-chan e-chan])]
-
-         (when m
-           (condp = c
-             ws-sub-chan (do
-                           (om/update-state! owner :datoms #(conj % (:data m)))
-                           (render owner (om/get-state owner :datoms))))
-           e-chan (if (= m :reset)
-                    (om/set-state! owner :datoms []))
-           (recur (alts! [ws-sub-chan select-chan e-chan]))))))
-   )
-  (did-mount
-   [_]
-   (let [{:keys [renderer camera scene scatter-plot w h]} (om/get-state owner)]
-     (. renderer (setSize w h))
-     (dommy/append! (om/get-node owner "plot") (.-domElement renderer))
-     (. renderer (setClearColor 0xEEEEEE 1.0))
-     (. scene (add scatter-plot))
-     (aset camera "position" "x" 200)
-     (aset camera "position" "y" -100)
-     (aset camera "position" "z" 100)
-     (aset scatter-plot "rotation" "y" 0)
-     (render owner (om/get-state owner :datoms))
-     (animate renderer camera scene (.getTime (js/Date.))))
+         (recur (alts! [down up move]))))
+     (let [{:keys [renderer camera scene scatter-plot w h]} (om/get-state owner)]
+       (. renderer (setSize w h))
+       (dommy/append! (om/get-node owner "plot") (.-domElement renderer))
+       (. renderer (setClearColor 0xEEEEEE 1.0))
+       (. scene (add scatter-plot))
+       (aset camera "position" "x" 200)
+       (aset camera "position" "y" -100)
+       (aset camera "position" "z" 100)
+       (aset scatter-plot "rotation" "y" 0)
+       (render owner (om/get-state owner :datoms))
+       (animate renderer camera scene (.getTime (js/Date.)))))
 
    )
   (render

      :sx 0
      :sy 0
      :down false
      :update-chan (chan)
      }))
  (will-mount
   [_]
   (do
     (let [{:keys [:renderer :camera :scene :scatter-plot :w :h]} (om/get-state owner)
           down (chan) up (chan) move (chan)]
       (events->chan js/window EventType.MOUSEDOWN down)
       (events->chan js/window EventType.MOUSEUP up)
       (events->chan js/window EventType.MOUSEMOVE move)
       (go-loop [[event c] (alts! [down up move])]
         (condp = c
           down (do

                                 "#EFBD2E"
                                 "#73B845"
                                 "#009BDD"])

(defn hide? [bounds d]
  (let [{:keys [low high]} bounds
        t (get-in d [:timestamp])]
    (and (>= t low) (< t high))))

(defn events->chan
  "Given a target DOM element and event type return a channel of
