f88992da61
The type checker now correctly handles unwrapping `Stream(T)` types for lambda arguments. A new `build_map_stream` function has been added to `rtl/streams.rs` to facilitate field access on streams. The `create-random-ohlc` function now returns a `Stream` instead of a `Series`. Examples have been updated to reflect these changes and demonstrate stream usage.
11 lines
207 B
Plaintext
11 lines
207 B
Plaintext
#use rtl
|
|
|
|
(do
|
|
(def src (create-random-ohlc 42 200))
|
|
|
|
(macro printx [s] `(fn [x] (print ~s x)))
|
|
|
|
(pipe [(.close src)] (printx "close="))
|
|
(pipe [(pipe [(.close src)] (SMA 20))] (printx "sma="))
|
|
)
|