Hi!
I just stumbled in the expose_stan_functions.R code over these lines:
# special cases
ODE_lines <- grep("integrate_ode(", lines, fixed = TRUE)
ODE_statements <- grep("integrate_ode(", lines, fixed = TRUE, value = TRUE)
I don’t quite get what is being done with the ODE stuff there. However, I think the regex should be expanded or changed as we have more integrate_ode calls to cover:
- integrate_ode
- integrate_ode_rk45
- integrate_ode_bdf
The last two exist in two flavors which are either in advanced or simple (advanced allows specification of tolerances); but I guess the flavors are irrelevant here. So I guess the right way to change the ODE handling code would be
# special cases
ODE_lines <- grep("integrate_ode", lines, fixed = TRUE)
ODE_statements <- grep("integrate_ode", lines, fixed = TRUE, value = TRUE)
which would catch all cases.
Would be great if someone knowledgable (Ben?) could confirm this, then I am happy to file an issue and a fix for it.
Thanks!
Sebastian