Learn R Programming

scanstatistics (version 0.1.0)

zip_statistic_term: Calculate a term in the sum of the logarithm of the ZIP window statistic.

Description

This function calculates a term which appears in the sum of the logarithm of the zero-inflated Poisson statistic for a given space-time window.

Usage

zip_statistic_term(q, p, dstar, ddagger, mu, y)

Arguments

q

Scalar; the relative risk.

p

Numeric vector of excess zero probabilities.

dstar

Numeric vector of estimates of the excess zero indicators, under the alternative hypothesis of an outbreak. Of same length as p.

ddagger

Numeric vector of estimates of the excess zero indicators, under the null hypothesis of no outbreak. Of same length as p.

mu

Numeric vector of given/estimated Poisson expected value parameters. Of same length as p.

y

Integer vector of observed counts. Of same length as p.

Value

A numeric vector of same length as input vector p.