waldpois: Wald Test Statistic

Description Usage Arguments Details Value References Examples

Description

Computes the Wald test statistic for the null hypothesis H0: theta = theta_0 where theta is mean of a Poisson distribution. This is discussed in Exercise 6.3.17 on page 386 of HMC.

Usage

1
waldpois(x, theta0)

Arguments

x

a vector of numeric elements, the sample.

theta0

a vector of numeric elements, each element is a mean you are checking the set against.

Details

this function uses the following mathematical function: (sqrt(length(x) / mean(x)) * (mean(x) - theta0))^2

Value

this function returns a floating point number for each element, the test statistic for each element in theta0

References

Hogg, R. McKean, J. Craig, A. (2018) Introduction to Mathematical Statistics, 8th Ed. Boston: Pearson.

Examples

1
2
3
x <- c(3.5, -6, 5, 4.444, 10)
theta <- 23
waldpois(x, theta)

austinragotzy/mathstat documentation built on May 13, 2019, 11:30 a.m.