How are the standard errors for posterior means (se_mean in print(stanfit)) computed please?
I couldn’t find the formula in the manual.
Thank you very much!
It should just be the estimated standard deviation of a parameter divided by the square root of the number of effective samples (for cmdstan: https://github.com/stan-dev/cmdstan/blob/develop/src/cmdstan/stansummary.cpp#L119). That answer your question?
There’s a fair bit of machinery that goes into estimating n_eff itself, so it’s kind of tricky.
That should be documented, but isn’t, in the MCMC chapter. I’ll add it next time: