mrc-ide / odin.dust

Compile odin to dust
https://mrc-ide.github.io/odin.dust
Other
3 stars 1 forks source link

Typo in porting from odin vignette #112

Closed lwhittles closed 1 year ago

lwhittles commented 1 year ago

https://github.com/mrc-ide/odin.dust/blob/1a59a871e40c98ec0c80b1b96aee032b25f422bc/vignettes/porting.Rmd#L176

Typo, this should be update(incidence) <- if (step %% 10 == 0) new else incidence + new

Otherwise: incidence[step] = new for step = 1, ..., 9 incidence[10] = incidence[9] + new