cplm-package {cplm}R Documentation

Tweedie compound Poisson linear models


The Tweedie compound Poisson distribution is a mixture of a degenerate distribution at the origin and a continuous distribution on the positive real line. It has been applied in a wide range of fields in which continuous data with exact zeros regularly arise. Nevertheless, statistical inference based on full likelihood and Bayesian methods is not available in most statistical software, largely because the distribution has an intractable density function and numerical methods that allow fast and accurate evaluation of the density did not appear until fairly recently. The cplm package provides likelihood-based and Bayesian procedures for fitting common Tweedie compound Poisson linear models. In particular, models with hierarchical structures or extra zero inflation can be handled. Further, the package implements the Gini index based on an ordered version of the Lorenz curve as a robust model comparison tool involving zero-inflated and highly skewed distributions.

The following features of the package may be of special interest to the users:

  1. All methods available in the package enable the index parameter (i.e., the unknown variance function) to be estimated from the data.

  2. The compound Poisson generalized linear model handles large data set using the bounded memory regression facility in biglm.

  3. For mixed models, we provide likelihood-based methods using Laplace approximation and adaptive Gauss-Hermit quadrature.

  4. A convenient interface is offered to fit additive models (penalized splines) using the mixed model estimation procedure.

  5. Self-tuned Markov chain Monte Carlo procedures are available for both GLM-type and mixed models.

  6. The package also implements a zero-inflated compound Poisson model, in which the observed frequency of zeros can generally be more adequately modeled.

  7. We provide the Gini index based on an ordered Lorenz curve, which is better suited for model comparison involving the compound Poisson distribution.


Yanwei (Wayne) Zhang <actuary_zhang@hotmail.com>


Dunn, P.K. and Smyth, G.K. (2005). Series evaluation of Tweedie exponential dispersion models densities. Statistics and Computing, 15, 267-280.

Frees, E. W., Meyers, G. and Cummings, D. A. (2011). Summarizing Insurance Scores Using a Gini Index. Journal of the American Statistical Association, 495, 1085 - 1098.

Zhang, Y (2013). Likelihood-based and Bayesian Methods for Tweedie Compound Poisson Linear Mixed Models, Statistics and Computing, 23, 743-757.

[Package cplm version 0.7-12 Index]