search for: amovingaverage

Displaying 1 result from an estimated 1 matches for "amovingaverage".

Did you mean: movingaverage
2017 Nov 29
1
DeSolve Package and Moving Average
...<- seq(START, FINISH, by=STEP) # Create a stock vector with initial values stocks <- c([?]) # Create an aux vector for the fixed aux values auxs <- c([?]) model <- function(time, stocks, auxs){ with(as.list(c(stocks, auxs)),{ [? ?lots of aux, flow, and stock functions? ? ] aMovingAverage <- ifelse(exists("ResultsSimulation")=="FALSE",10000,movavg(ResultsSimulation$TotalSales, 12, type = "s?)) return (list(c([?])) }) } # Call Solver, and store results in a data frame ResultsSimulation <- data.frame(ode(y=stocks, times=simtime, func = model,...