compute_logz: Compute COM-Poisson normalizing constante in log scale

Description Usage Arguments Details Value Author(s) References

Description

Computes the normalizing constant in the log scale usign the LogSumExp trick to avoid numerical issues (See details).

Usage

1
compute_logz(loglambda, mu, nu)

Arguments

loglambda

A vector of logarithm of the λ parameter.

mu

A vector of the μ parameter.

nu

A vector of dispersion parameters ν.

Details

logspace_add(a, b) = log(exp(a) + exp(b)) = b + log(1 + exp(a - b)), where b > a.

Value

The normalizing constant.

Author(s)

Eduardo Jr <edujrrib@gmail.com>

References

Wikipedia, LogSumExp. http://rstudio.com.


jreduardo/flexcm documentation built on May 8, 2019, 12:41 p.m.