neyman.unif.test: Neyman-Barton test for uniformity
Description
Performs Neyman-Barton test for the hypothesis of uniformity.
Usage
neyman.unif.test(x, nrepl=2000, k=5)
Arguments
x
a numeric vector of data values.
nrepl
the number of replications in Monte Carlo simulation.
k
the number of Legendre polynomials.
Value
A list with class "htest" containing the following components:
statisticthe value of the Neyman-Barton statistic.
p.valuethe p-value for the test.
methodthe character string "Neyman-Barton test for uniformity".
data.namea character string giving the name(s) of the data.
Details
The Neyman-Barton test for uniformity is based on the following statistic:
$$N_k = \sum_{j=1}^{k}{\left(\frac{1}{\sqrt{n}}\sum_{i=1}^{n}{\pi_j(x_i)}\right)^2},$$
where $\pi_j(x_i)$ are Legendre polynomials orthogonal on the interval [0,1].
The p-value is computed by Monte Carlo simulation.
References
Neyman J. "Smooth" test for goodness-of-fit // Scand. Aktuarietidsrift. 1937. V. 20. P. 149-199.