TestStatVariance: Variance of Cramer test statistics
Description
Calculates the variance of the test statistics calculated using the Cramer test.
Usage
TestStatVariance(n1, n2, sample, Regions)
Arguments
n1
an integer referring to the number of observations in the first sample.
n2
an integer reffering to the number of observations in the second sample.
sample
a (non-empty) numeric vector of data values.
Regions
a (non-empty) numeric vector of grid points to be used in the integration.
Details
sample should be the two samples of data that is to be tested using the Cramer test, concatinated.
Regions must be sorted from smallest to largest number. Regions must not contain any numbers smaller than the minimum value or larger than the maximum value of sample.
The result is more accurate when more grid points are used, however the use of more grid points could make the function run slower. It is recommended to use equally spaced grid points.