timepoint in data for est_naloxone needs to start from 1, but produces unhelpful error message when indexed from 0.
THN_data <- bennu::generate_model_data()
# start index at 0 not 1
THN_data$times <- THN_data$times -1
fit <- bennu::est_naloxone(THN_data)
produces the following error
Error in eval(ei, envir) :
Exception: model_distribution_covariate_model_namespace::model_distribution_covariate_model: times[sym1__] is 0, but must be greater than or equal to 1 (in 'string', line 74, column 2 to column 52)
failed to create the sampler; sampling not done
Should do some data checking in est_naloxone function.
timepoint
indata
forest_naloxone
needs to start from 1, but produces unhelpful error message when indexed from 0.produces the following error
Should do some data checking in
est_naloxone
function.