goldingn / pop

A Flexible Syntax for Population Dynamic Modelling :koala: :chart_with_upwards_trend:
Other
10 stars 2 forks source link

remove addition of dynamics #23

Closed goldingn closed 8 years ago

goldingn commented 8 years ago

Addition implies that transitions are commutative (i.e. the order is unimportant), but they aren't as the the order in the dynamic defines e.g. whether mortality occurs before or after other transitions, so influences the model (a bit).

instead could enable concatenation:

all <- c(stasis, growth, reproduction)

(ignoring the recursive argument in the generic)

or enable dynamic to act on other dynamics:

all <- dynamic(stasis, growth, reproduction)

I think I prefer the latter, but will mull it over