Summary method for fitted CLV models that provides statistics about the estimated parameters and information about the optimization process. If multiple optimization methods were used (for example if specified in parameter optimx.args), all information here refers to the last method/row of the resulting optimx object.

# S3 method for clv.fitted
summary(object, ...)

# S3 method for clv.fitted.transactions.static.cov
summary(object, ...)

# S3 method for summary.clv.fitted
print(
x,
digits = max(3L, getOption("digits") - 3L),
signif.stars = getOption("show.signif.stars"),
...
)

## Arguments

object

A fitted CLV model

...

Ignored for summary, forwarded to printCoefmat for print.

x

an object of class "summary.clv.no.covariates", usually, a result of a call to summary.clv.no.covariates.

digits

the number of significant digits to use when printing.

signif.stars

logical. If TRUE, ‘significance stars’ are printed for each coefficient.

## Value

This function computes and returns a list of summary information of the fitted model given in object. It returns a list of class summary.clv.no.covariates that contains the following components:

name.model

the name of the fitted model.

call

The call used to fit the model.

tp.estimation.start

Date or POSIXct indicating when the fitting period started.

tp.estimation.end

Date or POSIXct indicating when the fitting period ended.

estimation.period.in.tu

Length of fitting period in time.units.

time.unit

Time unit that defines a single period.

coefficients

a px4 matrix with columns for the estimated coefficients, its standard error, the t-statistic and corresponding (two-sided) p-value.

estimated.LL

the value of the log-likelihood function at the found solution.

AIC

Akaike's An Information Criterion for the fitted model.

BIC

Schwarz' Bayesian Information Criterion for the fitted model.

KKT1

Karush-Kuhn-Tucker optimality conditions of the first order, as returned by optimx.

KKT2

Karush-Kuhn-Tucker optimality conditions of the second order, as returned by optimx.

fevals

The number of calls to the log-likelihood function during optimization.

method

The last method used to obtain the final solution.

A list of additional options used for model fitting.

Correlation

Whether the correlation between the purchase and the attrition process was estimated.

estimated.param.cor

Correlation coefficient measuring the correlation between the two processes, if used.

For models fits with static covariates, the list additionally is of class summary.clv.static.covariates

and the list in additional.options contains the following elements:

Regularization

Whether L2 regularization for parameters of contextual factors was used.

lambda.life

The regularization lambda used for the parameters of the Lifetime process, if used.

lambda.trans

The regularization lambda used for the parameters of the Transaction process, if used.

Constraint covs

Whether any covariate parameters were forced to be the same for both processes.

Constraint params

Name of the covariate parameters which were constraint, if used.

The model fitting functions pnbd.

Function coef will extract the coefficients matrix including summary statistics and function vcov will extract the vcov from the returned summary object.

## Examples

# \donttest{

data("apparelTrans")

# Fit pnbd standard model, no covariates
clv.data.apparel <- clvdata(apparelTrans, time.unit="w",
estimation.split=40, date.format="ymd")
pnbd.apparel <- pnbd(clv.data.apparel)
#> Starting estimation...
#> Estimation finished!

summary(pnbd.apparel)
#> Pareto/NBD Standard  Model
#>
#> Call:
#> pnbd(clv.data = clv.data.apparel)
#>
#> Fitting period:
#> Estimation start  2005-01-03
#> Estimation end    2005-10-10
#> Estimation length 40.0000 Weeks
#>
#> Coefficients:
#>       Estimate Std. Error z-val Pr(>|z|)
#> r       0.7866     0.1324 5.942 2.81e-09 ***
#> alpha   5.3349     0.9027 5.910 3.42e-09 ***
#> s       0.3570     0.1838 1.943   0.0521 .
#> beta   11.6152    10.6598 1.090   0.2759
#> ---
#> Signif. codes:  0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
#>
#> Optimization info:
#> LL     -2879.4699
#> AIC    5766.9399
#> BIC    5781.0257
#> KKT 1  TRUE
#> KKT 2  TRUE
#> fevals 23.0000
#> Method L-BFGS-B
#>
#> Used Options:
#> Correlation FALSE

data("apparelStaticCov")
data.apparel.cov  <-
SetStaticCovariates(clv.data.apparel,
data.cov.life  = apparelStaticCov,
names.cov.life = "Gender",
data.cov.trans = apparelStaticCov,
names.cov.trans = "Gender",
name.id = "Id")

# fit model with covariates and regualization
pnbd.apparel.cov <- pnbd(data.apparel.cov,
reg.lambdas = c(life=2, trans=4))
#> Starting estimation...
#> Estimation finished!

#   and used regularization
summary(pnbd.apparel.cov)
#> Pareto/NBD with Static Covariates  Model
#>
#> Call:
#> pnbd(clv.data = data.apparel.cov, reg.lambdas = c(life = 2, trans = 4))
#>
#> Fitting period:
#> Estimation start  2005-01-03
#> Estimation end    2005-10-10
#> Estimation length 40.0000 Weeks
#>
#> Coefficients:
#>                Estimate Std. Error  z-val Pr(>|z|)
#> r              0.791772   2.120943  0.373    0.709
#> alpha          5.428158  14.764014  0.368    0.713
#> s              0.356247   2.889268  0.123    0.902
#> beta          11.503710 166.930678  0.069    0.945
#> life.Gender   -0.001246   0.499465 -0.002    0.998
#> trans.Gender   0.013320   0.352864  0.038    0.970
#>
#> Optimization info:
#> LL     -11.5172
#> AIC    35.0343
#> BIC    56.1631
#> KKT 1  TRUE
#> KKT 2  TRUE
#> fevals 46.0000
#> Method L-BFGS-B
#>
#> Used Options:
#> Correlation     FALSE
#> Regularization  TRUE
#>    lambda.life  2.0000
#>    lambda.trans 4.0000
#> Constraint covs FALSE
# }