mrc-ide / drjacoby

Flexible Markov chain monte carlo via reparameterization
https://mrc-ide.github.io/drjacoby/
Other
12 stars 5 forks source link

Theta named parameters #32

Closed bobverity closed 4 years ago

bobverity commented 4 years ago

Can we ensure that theta is passed around within R as a named vector, so that at least parameters can be accessed with theta["foo"] rather than theta[5]. This would only apply within R, no such luck within C++.

bobverity commented 4 years ago

No, because even R implementation is run from within Rcpp where theta is a vector of un-named doubles. Would have to pass names in separately, or use Rcpp objects instead. Dropping this idea for now.

bobverity commented 4 years ago

Should be possible via Rcpp::NumericVector. Should at least give this a go.

bobverity commented 4 years ago

Done and working. Still some issue eith coda::effectiveSize() causing tests to fail, but I think this is a separate issue.