Paste number 82992: side-effects

Paste number 82992: side-effects
Pasted by: foox
When:2 years, 7 months ago
Share:Tweet this! | http://paste.lisp.org/+1S1C
Channel:None
Paste contents:
Raw Source | XML | Display As
(let [ts (TimeSeries. "TataSteel" Second)
      ts-col (TimeSeriesCollection.)]
  (doseq []
    (doseq [tick (map #(vector (:date %)
			     ((comp second (fn [x] (nth x 2)) :ticks) %))
		    *data-buffer*)]
      (if (and tick (second tick))
	(.add ts (Second. (first tick)) (second tick))))
    (.addSeries ts-col ts)
    (let [frame (ChartFrame. "Test" 
			     (ChartFactory/createTimeSeriesChart 
			      "TataSteel"
			      "Time" 
			      "Price" 
			      ts-col
			      true
			      true
			      false))]
      (.pack frame)
      (.setVisible frame true))))

This paste has no annotations.

Colorize as:
Show Line Numbers

Lisppaste pastes can be made by anyone at any time. Imagine a fearsomely comprehensive disclaimer of liability. Now fear, comprehensively.