Importance Sampling

Use of Healpix, camb, CLASS, cosmomc, compilers, etc.
Post Reply
Katharina Borm
Posts: 6
Joined: February 18 2015
Affiliation: Argelander Institute for Astronomy, Univ. of Bonn

Importance Sampling

Post by Katharina Borm » February 18 2016


I am facing a question when running the importance sampling within CosmoMC. I would like to compute the new likelihood at all pre-sampled chain steps. How do I need to define the "redo_indep" parameter in this case? Or do I need to change something else as well?

From other CosmoCoffee comments, it sounded as if this was possible, but the best I can achieve is using only every tenth step...

cheers and many thanks in advance,

Antony Lewis
Posts: 1652
Joined: September 23 2004
Affiliation: University of Sussex

Re: Importance Sampling

Post by Antony Lewis » February 18 2016

If you are using stored .data files, the initial run needs to be done with indep_sample=1 to store everything for importance sampling.

You can also importance sample from text chain files (recomputing everything as needed), using redo_from_text=T. However the main advantage of importance sampling is that either you can thin (which loses little information) or you don't have to recompute things.

Post Reply