derivkit.likelihood_kit module#

Provides the LikelihoodKit class.

Typical usage examples#

>>> import numpy as np
>>> from derivkit import LikelihoodKit
>>>
>>> # Gaussian example
>>> data = np.linspace(-5.0, 5.0, 200)
>>> theta = np.array([0.0])
>>> cov = np.array([[1.0]])
>>> lkit = LikelihoodKit(data=data, model_parameters=theta)
>>> grid, pdf = lkit.gaussian(cov=cov)
>>>
>>> # Poissonian example
>>> counts = np.array([1, 2, 3, 4])
>>> mu = np.array([0.5, 1.0, 1.5, 2.0])
>>> lkit = LikelihoodKit(data=counts, model_parameters=mu)
>>> reshaped_counts, pmf = lkit.poissonian()