Bayesian inference

Functions

yli.bayesfactor_afbf(params, cov, n, hypothesis)

Compute an adjusted fractional Bayes factor for the hypothesis

Uses R BFpack library. See R documentation for BFpack.BF.

Returns:

Bayes factor for the hypothesis versus its complement

Return type:

yli.bayes_factors.BayesFactor

Result classes

class yli.bayes_factors.BayesFactor(factor, num_symbol, num_desc, denom_symbol, denom_desc)

A Bayes factor

denom_desc

Description of the hypothesis in the denominator (str)

denom_symbol

Symbol representing the hypothesis in the denominator (str)

factor

Value of the Bayes factor (float)

invert()

Invert the Bayes factor

Return type:

BayesFactor

num_desc

Description of the hypothesis in the numerator (str)

num_symbol

Symbol representing the hypothesis in the numerator (str)

summary()

Return a stringified summary of the Bayes factor

Return type:

str