Learn R Programming

MNM (version 0.95-0)

mv.ind.test: Independence Test

Description

Tests for independence of two vectors using different scores.

Usage

mv.ind.test(X, Y, score = "identity", method = "approximation", 
            n.simu = 1000, na.action = na.fail)

Arguments

Value

  • A list with class 'htest' containing the following components:
  • statisticthe value of the test statistic.
  • parameterthe degrees of freedom for the test statistic or the number of replications in the simulation.
  • p.valuethe p-value for the test.
  • null.valuethe specified null hypothesis value.
  • alternativea character string with the value 'two.sided'.
  • methoda character string indicating what type of test was performed.
  • data.namea character string giving the name of the two data matrices.

Details

This implements the independence tests as described in chapter 10 of the MNM book. Note that only inner test versions are implemented and that for the symmetrized sign score only the approximative method for the computation of the p-value is available.

References

Oja, H. (2010), Multivariate Nonparametric Methods with R, Springer.

Examples

Run this code
X <- rmvt(150,diag(1,3),df=3)
Y <- rmvt(150, matrix(c(1,0.5,0.5,1),nrow=2),df=3)

mv.ind.test(X, Y)
mv.ind.test(X, Y, method = "p")

mv.ind.test(X, Y, score = "si")
mv.ind.test(X, Y, score = "si", method = "p")

mv.ind.test(X, Y, score = "r")
mv.ind.test(X, Y, score = "r", method = "p")

mv.ind.test(X, Y, score = "sy")

Run the code above in your browser using DataLab