BayesMIEstimator

BayesMIEstimator#

class infomeasure.estimators.mutual_information.BayesMIEstimator(*data, cond=None, alpha: float | str, K: int = None, offset: int = 0, base: int | float | str = 'e', **kwargs)[source]

Bases: BaseBayesMIEstimator, MutualInformationEstimator

Estimator for the Bayes mutual information.

Bayesian mutual information estimator using Dirichlet prior with concentration parameter α. Provides principled handling of sparse data through Bayesian probability estimates.

Attributes:
*dataarray_like, shape (n_samples,)

The data used to estimate the mutual information. You can pass an arbitrary number of data arrays as positional arguments.

alphafloat | str

The concentration parameter α of the Dirichlet prior. Either a float or a string specifying the choice of concentration parameter.

Kint, optional

The support size. If not provided, uses the observed support size.

offsetint, optional

Number of positions to shift the data arrays relative to each other. Delay/lag/shift between the variables. Default is no shift.

See also

infomeasure.estimators.entropy.bayes.BayesEntropyEstimator

Bayesian entropy estimator with Dirichlet prior.

Notes

This estimator uses Bayesian probability estimates with a Dirichlet prior to compute mutual information through the entropy combination formula.

Note that the entropy combination formula is used (_generic_mi_from_entropy) not a dedicated implementation as other MI might have.