[Paper Review] Testing Closeness With Unequal Sized Samples
This paper proposes a statistical test for closeness between two discrete distributions with unequal sample sizes, introducing a novel, simple test statistic that achieves optimal sample complexity. It establishes tight bounds showing that $ m_1 = \Theta(n^{2/3}/\varepsilon^{4/3}) $ and $ m_2 = \Omega(\max\{n/\sqrt{m}_1\varepsilon^2, \sqrt{n}/\varepsilon^2\}) $ are necessary and sufficient for distinguishing $ p = q $ from $ \|p - q\|_1 \geq \varepsilon $, resolving the problem in the undersampled regime with improved dependence on $ n $ and $ \varepsilon $ compared to prior work.
We consider the problem of closeness testing for two discrete distributions in the practically relevant setting of \emph{unequal} sized samples drawn from each of them. Specifically, given a target error parameter $\varepsilon > 0$, $m_1$ independent draws from an unknown distribution $p,$ and $m_2$ draws from an unknown distribution $q$, we describe a test for distinguishing the case that $p=q$ from the case that $||p-q||_1 \geq \varepsilon$. If $p$ and $q$ are supported on at most $n$ elements, then our test is successful with high probability provided $m_1\geq n^{2/3}/\varepsilon^{4/3}$ and $m_2 = Ω(\max\{\frac{n}{\sqrt m_1\varepsilon^2}, \frac{\sqrt n}{\varepsilon^2}\});$ we show that this tradeoff is optimal throughout this range, to constant factors. These results extend the recent work of Chan et al. who established the sample complexity when the two samples have equal sizes, and tightens the results of Acharya et al. by polynomials factors in both $n$ and $\varepsilon$. As a consequence, we obtain an algorithm for estimating the mixing time of a Markov chain on $n$ states up to a $\log n$ factor that uses $ ilde{O}(n^{3/2} τ_{mix})$ queries to a "next node" oracle, improving upon the $ ilde{O}(n^{5/3}τ_{mix})$ query algorithm of Batu et al. Finally, we note that the core of our testing algorithm is a relatively simple statistic that seems to perform well in practice, both on synthetic data and on natural language data.
Motivation & Objective
- To address the fundamental problem of testing whether two discrete distributions are identical or $ \ell_1 $-distant when samples are of unequal size.
- To close the gap in sample complexity bounds for closeness testing in the undersampled regime, where sample sizes are smaller than the support size $ n $.
- To provide a unified, optimal tradeoff between sample sizes $ m_1 $ and $ m_2 $ drawn from distributions $ p $ and $ q $, respectively, for distinguishing $ p = q $ from $ \|p - q\|_1 \geq \varepsilon $.
Proposed method
- Proposes a new test statistic that combines empirical frequency differences with a normalization term to improve robustness in the unequal sample regime.
- Uses a two-part test: a standard $ \ell_1 $-based statistic for most parameter regimes, and a novel additional statistic when $ m_1 \approx n $.
- Applies concentration inequalities and moment-based analysis (via Valiant's framework) to bound error probabilities and establish optimality.
- Employs a Poissonization technique and moment comparison to derive lower bounds on required sample sizes.
- Derives tight sample complexity bounds by analyzing the tradeoff between $ m_1 $ and $ m_2 $, showing optimality to constant factors.
- Validates the practical performance of the test on synthetic data and real-world natural language data, such as synonym detection using bi-gram samples.
Experimental results
Research questions
- RQ1What is the optimal tradeoff between sample sizes $ m_1 $ and $ m_2 $ when testing closeness between two discrete distributions with unequal sample sizes?
- RQ2Can a single, simple test statistic achieve optimal performance across the full range of $ m_1 $ and $ m_2 $, including extreme regimes like $ m_1 \approx n $?
- RQ3How does the sample complexity of closeness testing change when one sample is significantly smaller than the other, compared to the equal-sample case?
- RQ4What is the information-theoretic lower bound on the number of samples required to distinguish $ p = q $ from $ \|p - q\|_1 \geq \varepsilon $ in the unequal sample setting?
- RQ5Can the proposed test be applied to improve existing algorithms, such as those estimating the mixing time of Markov chains?
Key findings
- The proposed test achieves optimal sample complexity: $ m_1 = \Theta(n^{2/3}/\varepsilon^{4/3}) $ and $ m_2 = \Omega(\max\{n/\sqrt{m}_1\varepsilon^2, \sqrt{n}/\varepsilon^2\}) $, matching lower bounds to constant factors.
- The tradeoff smoothly interpolates between the $ \Theta(n^{2/3}) $ bound for equal-sized samples and the $ \Theta(\sqrt{n}/\varepsilon^2) $ bound when one distribution is known.
- The test is optimal throughout the entire range of parameters, including the extreme case where $ m_1 \approx n $, which requires a novel additional statistic.
- The method improves the query complexity for estimating the mixing time of a Markov chain on $ n $ states from $ \tilde{O}(n^{5/3}\tau_{\text{mix}}) $ to $ \tilde{O}(n^{3/2}\tau_{\text{mix}}) $.
- The core test statistic is not only theoretically optimal but also empirically effective on both synthetic and real-world data, including natural language applications.
- The lower bound proof establishes that $ \Omega(n/\sqrt{m}_1\varepsilon^2) $ samples from $ q $ are necessary when $ m_1 \geq n^{2/3}/\varepsilon^{4/3} $, confirming the tightness of the upper bound.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.