Closed edsandorf closed 3 years ago
Could potentially be solved using an argument in the function specifying the distributions that defaults to it being a prior unless otherwise stated. It should keep the syntax clean for most cases except when specifying random parameters in a MIXL.
For example:
N(0, 1, "random")
or N(0, 1, FALSE)
or N(0, 1, "rpl")
This would require modification of the functions N()
, LN()
, TR()
and U()
such that they return an attribute indicating whether it is a prior or a parameter since this affects where the averaging happens in the optimization.
The syntax is Np()
for priors and N()
for random parameters. Consistent with the Dp
notation for the error when priors are specified.
Closing this issue for now and consider it resolved.
With the current syntax, the package can handle a MIXL with a combination of non-random and random parameters. I can also handle whether the mean and standard deviations have Bayesian priors, however, it cannot distinguish between a random parameter with fixed priors
beta_1 | N(0, 1)
and a non-random parameter with Bayesian priorsbeta_1 | N(0, 1)
.It is critical to think about this because changing the syntax down the line may lead to backwards incompatibility and breaking changes.