quadsv#
quadsv: kernel-based spatial pattern detection and comparison for spatial omics.
The public top-level API is organised in four layers:
Kernels —
MatrixKernel(dense / sparse),FFTKernel(regular grid),NUFFTKernel(irregular 2D coordinates). TheKernelandMatrixKernelBaseABCs live inquadsv.kernelsand are intended for backend authors.Statistical tests —
spatial_q_test()andspatial_r_test(). A single entry point per test dispatches on the kernel type (matrix, FFT, or NUFFT). Signature:(x, kernel, null_params=None, return_pval=True, is_standardized=False).Detectors —
DetectorIrregularconsumesanndata.AnnData(irregular grids, matrix/NUFFT backends);DetectorGridconsumesspatialdata.SpatialData(regular grids, FFT backend).Comparators — cross-sample pattern comparison:
ComparatorIrregularon a list of AnnData (NUFFT backend);ComparatorGridon a list of SpatialData (FFT backend).