Getting the intrinsic variance for estimators

11 views
Skip to first unread message

Alex Reeves

unread,
Oct 19, 2021, 12:58:33 PM10/19/21
to emcee users
Dear all, 

probably a very basic question but I am fairly new to Emcee. In the documentation, there is a long discussion about the autocorrelation time and how to estimate it.The variance in our integral from the MCMC is given as: sigma**2=(tau_f/N) * VAR(f(theta)). The documentation then goes on to state something along the lines of "if we can estimate tau_f then we can know how many samples we need for sub percent precision". My questions- how do we know what VAR(f(theta)) is?- for example for a 1-D posterior for a parameter in a model where I believe the required f(theta) would be a delta function for each value of the parameter to map out the 1D posterior distribution. 

In more general terms I would like to get a better handle on when I can know when my chains are sufficiently converged and that I can trust the posteriors- is it enough to just have a stable estimate of tau_f (i.e. have a large enough N that the N = 100tau_f criterion is met) or do I also need to know something about the variance for the particular f(theta) I am choosing? 

Thank you very much in advance, 

Alex Reeves 

Dan Foreman-Mackey

unread,
Oct 20, 2021, 1:39:37 PM10/20/21
to Alex Reeves, emcee users
Hi Alex,

The Var(f(theta)) discussed in the docs is actually the posterior variance for the function f(theta). One way to think about this is that your sampling error is a relative error wrt to precision with which you can measure f(theta).

When looking at convergence, I generally don't explicitly consider Var(f) (in part because any estimator of Var(f) will *also* have sampling uncertainty). If you follow a rule of thumb like N > 100 tau, you'll generally have a large enough number of effective samples that the sampling error is negligible compared to the posterior variance, so that's the main convergence criterion I would consider. But, if you wanted to make a statement about the magnitude of the Monte Carlo error then you'd want to look at Var(f) more explicitly.

Hope this helps!
Dan

--
You received this message because you are subscribed to the Google Groups "emcee users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to emcee-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/emcee-users/19b9b528-e181-4c9c-94f2-5adbe2599075n%40googlegroups.com.


--
Dan Foreman-Mackey
Associate Research Scientist
Flatiron Institute
Reply all
Reply to author
Forward
0 new messages