Stan algorithm


Hi all,

In literature in Bayesian framework, such as this paper, to get published in a high-rank journal they often provide Gibbs and/or MH sampler in detail. I am going to submit my paper where I discuss a statistical model, apply to a medical context, and use Stan for estimation but I just use Stan, no detail about the algorithm.

So my concern is that, if I want to do something like that:

  1. What should I do? Of course Stan use HMC and it is more difficult.

  2. Have you seen some articles doing something like that in literature? Could you suggest it?

Thank you for reading this post,


It some journals these days you can probably get away with just saying that you used Stan. For other journals, the reviewers and / or editors are going to have little to no idea what Stan is or why one would use it over alternatives. If the focus is applied, I would just provide a lot of citations to papers on Stan and to BDA3 and if someone asks you to elaborate, then you can do so in the revision. I would (try to) resist providing results “for comparison” with “familiar approaches” like Gibbs and / or MH because at best those results are going to be similar to what Stan gives and at worst they are just wrong with a finite number of iterations.


I should note that the custom samplers implemented in those papers are often fragile and yield the wrong answers, ultimately confusing the methodological point trying to be made by the authors! Always be suspicious when they spend a bunch of time describing their algorithm and then almost no time about initial conditions, number of chains, diagnostics, etc.

For the dynamic HMC algorithm used in Stan might I suggest


You should say which version of Stan you use, and ideally make your data and code to produce all of the results mentioned in the paper available.

But the version number of Stan will nail down the specific algorithm.


There’s quite a large literature that uses BUGS, and they often just cite that they use BUGS. The equivalent bit of code would be the BUGS or Stan program.