The Spatial Cramér–von Mises Test of Independence under β \beta -Mixing: Asymptotic Theory and Python Implementation

Marco C. Mandap · 2026

Read The Spatial Cramér–von Mises Test of Independence under β \beta -Mixing: Asymptotic Theory and Python Implementation by Marco C. Mandap (2026) in the Tower of Babel, a free online library of public-domain works preserved in clean, searchable text. No sign-up. The full text is served as a plain-text file at a predictable URL, where text is present: https://antarctic-labs.com/tower-of-babel/arxiv-2605-19164.txt.

Introduction

Marco Mandap builds a Cramér-von Mises test for complete spatial randomness that does not depend on origin placement. It averages corner gaps between observed and uniform patterns over all cube corners, with a fast closed-form formula. In one dimension it matches the classic rank test; in two it matches Zimmerman's origin-invariant form. Under random placement, the process tends to a centered Gaussian process with explicit cross-corner covariance. Monte Carlo runs show sound calibration and sensitivity against fixed non-uniform alternatives.

Catalog record

CREATORMarco C. Mandap
YEAR2026
COLLECTIONPAPERS
FORMATTXT
FILE SIZE86918
LICENSEhttp://creativecommons.org/licenses/by/4.0/
RIGHTSCC BY
SOURCEarXiv

Source: https://arxiv.org/abs/2605.19164

Browse the full library · About the Tower of Babel

Full text

The opening of the work, from the library's hosted text:

The Spatial Cramér–von Mises Test of Independence under β \beta -Mixing: Asymptotic Theory and Python Implementation Marco C. Mandap Abstract We derive the asymptotic distribution of the spatial Cramér–von Mises statistic for testing bivariate independence in stationary random fields on ℝ 2 \mathbb{R}^{2} under polynomial β \beta -mixing dependence, and document the Python implementation that reproduces all simulation results. The classical Cramér–von Mises test assumes i.i.d. observations; we extend it to spatially dependent data by combining three ingredients: (i) a Davydov-type covariance bound that yields integrability of the spatial covariance kernel under the mixing condition θ > 2 ​ ( 2 + δ ) / δ \theta>2(2+\delta)/\delta ; (ii) a reformulation of the inner-form test statistic as a degenerate U-statistic of order 2 with a product kernel Q = G 1 ⊗ G 2 Q=G_{1}\otimes G_{2} , following De Wet (1980); and (iii) an extension of Gregory’s (1977) U-statistic limit theorem to β \beta -mixing sequences via Yoshihara (1976). This approach bypasses the functional central limit theorem entirely. The limit distribution is a weighted sum of correlated χ 1 2 \chi^{2}_{1} variables whose eigenvalues factor as products of marginal eigenvalues; in the small-bandwidth limit, the correlation vanishes and the limit reduces to a weighted sum of independent χ 1 2 \chi^{2}_{1} variables. Explicit eigenvalue formulas are given for three common weight functions (uniform, optimal normal, Anderson–Darling), producing computable critical values. The software generates Matérn random fields by circulant embedding, computes the test statistic via the inner-form kernel decomposition, evaluates asymptotic critical values by Monte Carlo on the limit distribution, and runs permutation-based alternatives. Competing tests (Mantel, cross- K K , distance covariance) are included for power comparisons. Simulation experiments show that the Anderson–Darling weight achieves the best power across Gaussian and t t -copula alternatives, while the Mantel and cross- K K tests have no power against cross-dependence in spatially correlated fields. Keywords: spatial statistics; goodness-of-fit; Cramér–von Mises test; \beta -mixing; U-statistics; random fields; simulation; Python AMS 2020 subject classification: 62G10; 62M40; 60F05; 60G60 1 Introduction The Cramér–von Mises statistic measures the integrated squared difference between an empirical and a hypothesised cumulative distribution function. For independent data the classical theory is well understood: the limit distribution is a weighted sum of \chi^{2}_{1} variables whose weights are the eigenvalues of the covariance kernel [ 1 , 9 ] . For spatially dependent data—common in geostatistics, environmental monitoring, and spatial econometrics—the dependence structure must be explicitly controlled. This paper gives a derivation of the asymptotic distribution for a spatial Cramér–von Mises test of bivariate independence , together with a complete Python implementation and simulation study. The null hypothesis H_{0} is that the marginal components X_{s} and Y_{s} of the bivariate random field Z_{s}=(X_{s},Y_{s}) are independent, so that the joint CDF factors as H(x,y)=F_{1}(x)F_{2}(y) . Under H_{0} , the probability integral transform U_{s}=F_{1}(X_{s}) and V_{s}=F_{2}(Y_{s}) are marginally uniform on [0,1] , reducing the spatial CvM statistic to De Wet’s [ 8 ] U-statistic form (Section 11.4 ). We work in \mathbb{R}^{2} with a stationary \beta -mixing random field satisfying Assumption 11.6 , a compactly supported kernel smoother, and a sequence of spatial lattices whose mesh tends to zero. Our main result (Theorem 11.28 ) states that under polynomial mixing decay, the centred and normalised test statistic converges in distribution to a weighted sum of correlated \chi^{2}_{1} variables whose eigenvalues factor as products of marginal eigenvalues. In the small-bandwidth limit, the correlation vanishes and the limit reduces to the classical i.i.d. form. Two features distinguish our approach from previous work: 1. U-statistic route. Rather than proving weak convergence in C([0,1]) or \ell^{\infty}(\mathbb{R}) —which requires tightness via Arzelà–Ascoli and a functional central limit theorem for mixing fields—we reformulate the spatial CvM statistic as a degenerate U-statistic of order 2 [ 13 , 17 ] . Gregory’s theorem [ 10 ] then yields the limit distribution from scalar convergence alone, and Yoshihara’s [ 23 ] extension to \beta -mixing sequences handles the spatial dependence. This bypasses the functional CLT entirely. 2. Eigenvalue factorization. The inner form of the CvM statistic (using empirical marginals) yields a U-statistic kernel that factors as a product of marginal kernels: Q=G_{1}\otimes G_{2} . Consequently, the eigenvalues factor as products of marginal eigenvalues: \gamma_{jk}=\lambda^{(1)}_{j}\cdot\lambda^{(2)}_{k} (De Wet [ 8 ] ; Theorem 11.31 ). This reduces the two-dimensional spectral problem to two one-dimensional problems. Explicit eigenvalue formulas for three common weight functions (uniform, optimal normal, Anderson–Darling) give computable critical values without numerical integration. The accompanying Python implementation reproduces all simulation results and provides reusable components for researchers who wish to apply or extend the test. The software covers: (i) computation of the spatial CvM test statistic via the inner-form kernel decomposition; (ii) asymptotic critical values from the limit distribution; (iii) permutation-based inference for finite-sample p -values; (iv) data generation under both the null hypothesis (independent Matérn fields) and alternatives (Gaussian and t -copula dependence); (v) competing tests (Mantel, cross- K , distance covariance) for power comparisons. The paper is organised as follows. Sections 2 – 10 describe the software: package architecture, test statistic computation, asymptotic critical values, data generation, competing tests, simulation experiments, design decisions, verification, and a practical usage guide. Section 11 develops the full asymptotic distribution theory, including covariance bounds, integrability, asymptotic covariance, the U-statistic reformulation, the limit distribution theorem, and the eigenvalue structure. Section 12 discusses extensions and practical recommendations. Appendices A – C provide complete epsilon-delta proofs of the Riemann-sum convergence results, the alternative functional CLT route via Bernstein blocking, and algorithm pseudocode. 2 Package Architecture The simulation code is organised into nine modules, each responsible for a distinct stage of the pipeline. Table 1 maps each module to its role and the theoretical section it implements. Table 1: Module summary and relationship to the theoretical paper. Module Role Theory config.py Experiment configs — matern.py Matérn field generation § 11.1 (stationary fields) copula.py Copula alternatives, competing tests § 7 , § 6 weights.py Weight functions, eigenvalues, kernels § 11.6 (eigenvalues) statistic.py CvM statistic, permutation test § 11.4 – 11.5 critical_values.py Asymptotic critical values § 11.6 (critical values) simulation.py Experiment runners § 7 output.py CSV and L a T e X output — run_all.py Master entry point — The data flow proceeds as follows: 1. A configuration object ( SimConfig , PowerConfig , etc.) specifies the experiment parameters. 2. matern.py or copula.py generates spatial data (U,V)\in[0,1]^{n\times 2} on an m\times m lattice. 3. statistic.py computes the CvM test statistic T_{n}^{\mathrm{cent}} using the inner-form kernel. 4. The decision rule compares T_{n}^{\mathrm{cent}} against asymptotic critical values from critical_values.py , or obtains a permutation p -value. 5. simulation.py aggregates results over B or M replications. 6. output.py formats results as CSV and L a T e X tables. 3 The Spatial CvM Test Statistic: Formulation and Implementation 3.1 Mathematical formulation The null hypothesis is H_{0}\colon X_{s} and Y_{s} are independent, so that the probability integral transform U_{s}=F_{1}(X_{s}) and V_{s}=F_{2}(Y_{s}) are marginally \mathrm{Uniform}(0,1) . The centered spatial CvM statistic is T_{n}^{\mathrm{cent}}=T_{n}-\mu_{n},\qquad T_{n}=\frac{1}{n}\sum_{i=1}^{n}\sum_{j=1}^{n}\hat{Q}(Z_{i},Z_{j}), (3.1) where n=m^{2} is the number of lattice sites, \mu_{n}=n^{-1}\sum_{i}\hat{Q}(Z_{i},Z_{i}) is the centering constant, and \hat{Q} is the inner-form kernel \hat{Q}\bigl((u_{i},v_{i}),\,(u_{j},v_{j})\bigr)=\hat{G}_{U}(u_{i},u_{j})\;\hat{G}_{V}(v_{i},v_{j}), (3.2) with the marginal kernel decomposition \hat{G}_{W}(s,t)=G_{W}(s,t)+A_{W}(s)+A_{W}(t)+B_{W}. (3.3) Here G_{W} is the true-CDF kernel computed from the weight function W ,

Read the complete text