Closed petercolberg closed 8 years ago
Hi Peter. If this is something you'd like to pursue, an ImmutableOnlineStats package that extends OnlineStats would be pretty cool. There are still things changing with OnlineStats, but you're right that this looks like too big of a breaking change.
Now that Julia 0.4.0 has been released, this seems a good opportunity to introduce some breaking changes to the StreamStats package that will make it suitable for a broader range of use cases.
As a proof of concept, I revised Moments to use an immutable type.
Moments may be used as a scalar (bits) type as before:
Values are accumulated using the + operator, which allows for an in-place update syntax.
Moments may be used in an array, and the stats elements may be accumulated using
sum()
: