Observed since 20 Oct, 18:42 UTC
No superseded metadata states collected. Unchanged observations do not create new revisions.
Actuarial probability distributions for P&C loss modeling: severity and frequency families, MLE fitting, layer statistics, goodness-of-fit.
Python library for P&C loss distributions. Severity and frequency families follow the parameterizations in Klugman, Loss Models. Every severity distribution exposes layer statistics (LEV, excess pure premium, ILF) as methods. MLE accepts right-censored and one- or two-sided truncated samples.
pip install actudist
From source:
git clone https://github.com/CosmikArt/actudist.git
cd actudist
pip install -e ".[dev]"
import numpy as np
from actudist import DistributionFitter, GoodnessOfFit
from actudist.severity.lognormal import Lognormal
rng = np.random.default_rng(42)
claims = Lognormal(mu=8.0, sigma=1.2).rvs(size=2000, random_state=rng)
fit = Lognormal()
fit.mle_fit(claims)
print(f"mu={fit.mu:.3f} sigma={fit.sigma:.3f}")
print(f"AIC={fit.aic(claims):.1f} BIC={fit.bic(claims):.1f}")
print(f"LEV(50000)={fit.limited_expected_value(50_000):.1f}")
print(f"EPP(50000)={fit.excess_pure_premium(50_000):.1f}")
fitter = DistributionFitter(["Lognormal", "Pareto", "Weibull"])
ranking = fitter.fit_and_rank(claims, criterion="aic")
for row in ranking:
print(f"{row['name']:12s} aic={row['aic']:.1f}")
gof = GoodnessOfFit(fit, claims)
result = gof.ks_test(n_boot=200, random_state=42)
print(f"KS stat={result['statistic']:.4f} p={result['p_value']:.3f}")
actudist.severity: 13 continuous distributions (Exponential, Pareto,
Lognormal, Weibull, Gamma, Burr XII, Log-Logistic, Paralogistic and its
inverse, Inverse Gaussian, Transformed and Inverse Transformed Gamma,
Transformed Beta).actudist.frequency: Poisson, Binomial, Geometric, Negative Binomial,
ZIP, ZINB.actudist.fitting: registries and DistributionFitter for AIC/BIC
ranking.actudist.gof: KS and Anderson-Darling with parametric-bootstrap
p-values, chi-squared, PP and QQ plots.actudist.layers: excess pure premium, ILF, finite-layer expected loss.profile_likelihood_ci lives on the base class; call it on any fitted
instance.
Run pytest before sending a PR.
Isaac López
MIT License. See LICENSE.
Download counts and popularity will appear here as the collector receives them.
| Version | Published | Direct dependencies | Open version |
|---|---|---|---|
| 0.1.0 | 2 May 2026 | 7 |
This describes our collected data; it is not a security assessment.
Shared repository data · GitHub
Public sponsor counts have not been collected. These signals belong to the repository owner.
github · 1 observations shown. Missing days are unknown.
| Date / source period | Value | Observed at |
|---|---|---|
| 2026-10-22 | 0 | 2026-10-22T18:44:41.1689670Z |
Observed since 20 Oct, 18:42 UTC
No superseded metadata states collected. Unchanged observations do not create new revisions.
package:6f68aa265bae6757040e09743d226b9f52d0d39ac8cba3f856f12383d00800af