The GraphRankTest package implements the RISE framework for two-sample testing using rank/graph matrices constructed from either raw data \(X, Y\) or a pre-computed similarity matrix \(S\).
RISE(): construct a nonnegative symmetric rank/graph matrix \(R\) (k-NN, k-MST, or minimum-distance pairing variants), and compute a Hotelling-type quadratic statistic with asymptotic and optional permutation p-values.
From a similarity matrix \(S\), the procedure builds \(R\) using one of:
RgNN / RoNN: k-nearest-neighbor graph (graph-induced ranks vs. overall ranks)
RgMST / RoMST: k-minimum spanning trees (graph-induced ranks vs. overall ranks)
RoMDP: k-minimum-distance non-bipartite matchings (overall ranks)
Let \(U_x=\sum_{i,j\in X}R_{ij}\), \(U_y=\sum_{i,j\in Y}R_{ij}\). Under the permutation null, the centered vector \((U_x,U_y)\) has a tractable covariance, yielding a chi-square(2) limiting test.
library(GraphRankTest)
?RISE
help(package = "GraphRankTest")
Maintainer: Doudou Zhou ddzhou@nus.edu.sg (ORCID)
Authors:
Hao Chen hxchen@ucdavis.edu (ORCID)
Zhou, D. and Chen, H. (2023). A new ranking scheme for modern data and its application to two-sample hypothesis testing. In COLT 2023, PMLR, 3615–3668.
RISE