Learn R Programming

scanstatistics (version 0.1.0)

window_zip_statistic: Calculate the ZIP statistic for a single space-time window.

Description

Calculate the single-window statistic for the zero-inflated Poisson distribution using the EM algorithm.

Usage

window_zip_statistic(p, mu, y, ...)

Arguments

p

A numeric vector of the given/estimated excess zero probabilities corresponding to each count.

mu

A numeric vector of the given/estimated Poisson expected value parameters corresponding to each count. Of same length as p.

y

An integer vector of the observed counts, of same length as p.

...

Named parameters passed to zip_em_estimates.

Value

A scalar, the (logarithm of the) ZIP statistic.