Skip to contents

The one-time, R-only (main-thread) half of the kernel: parses the prior column and hands the result to src/priorDensity.cpp as a heap-allocated rx_prior_spec_t, wrapped in an R external pointer with a finalizer. rxPriorLogDensityEval() (inst/include/rxode2prior.h) – reachable through rxode2's C function-pointer table – then evaluates it with no R/Rcpp call of any kind, safe to call from inside an OpenMP-parallel objective/gradient evaluation.

Usage

rxPriorBuildSpec(ui, method = c("general", "nwpri", "tnpri"))

Arguments

ui

rxode2 ui model

method

"general" (default), "nwpri" or "tnpri"; see this file's header comment for what differs

Value

external pointer to a rx_prior_spec_t

Author

Matthew L. Fidler