py21cmmc.likelihood.LikelihoodNeutralFraction#

class py21cmmc.likelihood.LikelihoodNeutralFraction(redshift=5.9, xHI=0.06, xHI_sigma=0.05)[source]#

A likelihood based on the measured neutral fraction at a range of redshifts.

This likelihood is vectorized i.e., it accepts an array of astro_params.

The log-likelihood statistic is a simple chi^2 if the model has xHI > threshold, and 0 otherwise.

Methods

__init__([redshift, xHI, xHI_sigma])

Neutral fraction likelihood/prior.

computeLikelihood(model)

Compute the likelihood.

get_fiducial_model()

Compute and return a model dictionary at the fiducial set of parameters.

lnprob(model, data, sigma)

Compute the log prob given a model, data and error.

reduce_data(ctx)

Return a dictionary of model quantities from the context.

setup()

Perform post-init setup.

Attributes

chain

Reference to the LikelihoodComputationChain containing this core.

cmb_modules

All CMB core modules that are loaded.

coeval_modules

All coeval core modules that are loaded.

core_primary

The first core that appears in the requirements.

emu_modules

All emulator core modules that are loaded.

lightcone_modules

All lightcone core modules that are loaded.

parameter_names

Names of the parameters of the full chain.

required_cores

threshold