nntest: Nearest neighbor(NN) test for multivariate equal distribution

Description Usage Arguments Details References Examples

Description

Hypothesis testing problems can use permutation test. For equal distribution tests, nntest can faciliate multivariate tests.

Usage

1
nntest(x,y)

Arguments

x

sample data from a specific distribution

y

sample data from another different distribution

Details

user should be noted that x and y must have compatible number of dimension

References

Statistic computing with R. Maria L. Rizzo

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
## Not run: 
mat=matrix(0,10,1)
for(i in 1:10){
    x=rnorm(100)
    y=rnorm(100)*(1+i/10)
    mat[i]=nn.test(x,y)
    }
plot(mat,ylim=c(0,0.5),main="different variance")

## End(Not run)

Scopia/StatComp18053 documentation built on May 22, 2019, 2:44 p.m.