Plotting script - s-ilic/ECLAIR GitHub Wiki

The ECLAIR suite includes a script, ECLAIR_plots.py, for plotting results from MCMC and helping diagnostics potential issues with the chains. Basic help about the script can be obtained by using the command:

python ECLAIR_plots.py -h

We detail in the following all options of the script.

Basic script options

  -k LIST, --keep LIST  Keep only some parameters for analysis; argument should
                        be a list of comma-separated parameter indexes.
                        > Example: "0,5,7-8"  (hyphens indicate a range)
                        > Default: keep all parameters.

One may not be interested in plotting all the parameters of the MCMC, especially if nuisance parameters are present or if the model involves an overall very large number of parameters. This option offers the user to provide a list of parameter indexes that will be the only one kept for the rest of the analysis. The indexing of the parameters corresponds to their ordering in the corresponding chain .ini file.

  -b N, --burn-in N     If N >= 1, int(N) is the number of burned-in steps.
                        If 0 <= N < 1, float(N) is the fraction of burned-in steps
                        > Default: 0 (no burn-in)

This option allows the user to apply some "burn-in" to the chain, i.e. to remove a fraction (or a specific number) of samples from the beginning of the chain. This is done in order to remove the initial phase of the MCMC before the chain has converged to the typical set of the posterior.

  -t N, --thin N        Thin the chains so as to keep only every int(N)th step.
                        > Default: 1 (no thinning)

This option allows the user to perform some "thinning" in the chain, i.e. to keep only every Nth sample from the chain. This is usually done in order to reduce the correlation between samples and keep only samples as independent from each other as possible for the final analysis.

  -w N, --thin-walk N   Thin the walkers so as to keep only every int(N)th walker.
                        > Default: 1 (no walker thinning)

The user also has the possibility to thin the number of walkers in the chains. This is generally not recommended for computing the final results from the MCMC (marginalized posteriors, credibility intervals, etc.) as the ensemble sampling method is designed to benefit from having as many walkers as possible. This option is included for the practical purpose of plotting diagnostics interactively, where a very large number of walkers can lead to very slow performance on the user's computer.

The two last options (-og/--output-getdist and -p/--plots) are described in their own dedicated pages: