Hi everyone, I was checking the stan code for arma models in brms package and I saw that the prior distribution for the ma coefficient is
target += normal_lpdf(ma | 0, 0.5) - 1 * log_diff_exp(normal_lcdf(1 | 0, 0.5), normal_lcdf(-1 | 0, 0.5));
My question is, Why? @paul.buerkner
These additional terms make sure that the constant for the (truncated) prior is correctly included so that computation of marginal likelihood estimates on the basis of the model are including all constants (otherwise they do not yield correct results).
Next time, please use the Interfaces - brms tag for brms related questions.
1 Like