Closed femtotrader closed 8 months ago
See https://joshday.github.io/OnlineStats.jl/latest/api/#OnlineStatsBase.FilterTransform
I meant to split out Filter
and Transform
as separate wrappers but I guess I never got around to it.
Thanks @joshday
Hello,
I'm looking for a way to wrap a function which could extract a field of an observation and feed its value to a OnlineStat object.
I found in OnlineStats doc
CallFun
which callf(o)
each time an observationdata
is being updated but what I'm looking for is exactly the opposite: callf(data)
, feedf(data)
too
I'm aware I can directly dofit!(o, f(data)
but I want to dofit!(wrapped_o, data)
wherewrapped_o
contains both OnelineStato
and functionf
Does such a wrapper exists in OnlineStats? (or in OnlineStatsBase) If not how can it be implemented?
My use case:
I want to wrap the EMA indicator in a
ValueExtractor
object with a function likecandle -> candle.close
Something likeKind regards