GetDist: samples.loglikes actually chi2?

Use of Cobaya. camb, CLASS, cosmomc, compilers, etc.
Post Reply
Agne Semenaite
Posts: 10
Joined: June 08 2020
Affiliation: Max Planck Institute for Extraterrestrial Physics

GetDist: samples.loglikes actually chi2?

Post by Agne Semenaite » July 02 2021


I have been comparing samples.loglikes values with the logL values for the same chains read in with the 'anesthetic' package and find that getdist version gives values that are higher by a factor of 2. I also saw that in the getdist loadChains function loglikes are defined as "loglikes: if loading from arrays of samples, corresponding list of arrays of -2 log(likelihood)".

I have tried this logL getdist vs anesthetic comparison for chains produced with CosmoMC and nested sampling chains obtained with CosmoSIS and got the same result.

In all the documentation I was able to find samples.loglikes is described as -log(likelihood) or chi2/2 - is it at all possible that this might not be the case for certain chains or that I may have misunderstood the documentation somehow and samples.loglikes is actually -2log(likelihood) or chi2?

Sorry for perhaps a silly question but I would really appreciate a clarification!

Thanks a lot!

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

Re: GetDist: samples.loglikes actually chi2?

Post by Antony Lewis » July 03 2021

The first column in getdist chains should always be -log(likelihood), that docstring was wrong.

This may or may not be normalized to have a sensible interpretation in terms of chi2/2.

Post Reply