CMA.Rd
CMA
creates a streaming algorithm that can be used to
keep track of the mean of incoming values.
An R6Class
generator object
update()
Resets the CMA
streamer object.
mean <- CMA$new(c(1, 2))
mean$update(c(3, 4))
mean$value
#> [1] 2.5
#> [1] 2.5
## ------------------------------------------------
## Method `CMA$new`
## ------------------------------------------------
mean <- CMA$new()
## ------------------------------------------------
## Method `CMA$update`
## ------------------------------------------------
mean <- CMA$new()
mean$update(c(1, 2))