zipfpssVariance {zipfextR}R Documentation

Variance of the Zipf-PSS distribution.

Description

Computes the variance of the Zipf-PSS distribution for given values of parameters α\alpha and λ\lambda.

Usage

zipfpssVariance(alpha, lambda, isTruncated = FALSE)

Arguments

alpha

Value of the α\alpha parameter (α>3\alpha > 3).

lambda

Value of the λ\lambda parameter (λ>0\lambda > 0).

isTruncated

Logical; if TRUE Use the zero-truncated version of the distribution to calculate the expected value (default = FALSE).

Details

The variance of the Zipf-PSS distribution only exists for α\alpha values strictly greater than 3. The value is obtained from the law of total variance that says that:

Var[Y]=E[N]Var[X]+E[X]2Var[N],Var[Y] = E[N]\, Var[X] + E[X]^2 \, Var[N],

where X follows a Zipf distribution with parameter α\alpha, and N follows a Poisson distribution with parameter λ\lambda. From where one has that:

Var[Y]=λζ(α2)ζ(α)Var[Y] = \lambda\, \frac{\zeta(\alpha - 2)}{\zeta(\alpha)}

Particularlly, if one is working with the zero-truncated version of the Zipf-PSS distribution. This values is computed as:

Var[YZT]=λζ(α)ζ(α2)(1eλ)λ2ζ(α1)2eλζ(α)2(1eλ)2Var[Y^{ZT}] = \frac{\lambda\, \zeta(\alpha)\, \zeta(\alpha - 2)\, (1 - e^{-\lambda}) - \lambda^2 \, \zeta(\alpha - 1)^2 \, e^{-\lambda}}{\zeta(\alpha)^2 \, (1 - e^{-\lambda})^2}

Value

A positive real value corresponding to the variance of the distribution.

References

Sarabia Alegría, JM. and Gómez Déniz, E. and Vázquez Polo, F. Estadística actuarial: teoría y aplicaciones. Pearson Prentice Hall.

Examples

zipfpssVariance(4.5, 2.3)
zipfpssVariance(4.5, 2.3, TRUE)

[Package zipfextR version 1.0.2 Index]