Table of Contents
Fetching ...

Sequential One-Sided Hypothesis Testing of Markov Chains

Greg Fields, Tara Javidi, Shubhanshu Shekhar

TL;DR

The paper tackles sequential composite hypothesis testing for Markov chains by extending Wald’s SPRT to a setting with an unknown alternative, using a data-driven estimator to form a likelihood-ratio process. A central idea is to replace the unknown alternative with an estimator whose pointwise log-loss regret is $\mathcal{O}(\log t)$, enabling the test to asymptotically match SPRT performance in the simple case and to yield explicit stopping-time bounds in the Markov case via the stationary-averaged KL divergence $D_M(\boldsymbol{Q} \parallel \boldsymbol{P})$. Ville’s inequality ensures type-1 error control, while Markov Wald’s identity facilitates analysis of the stopping time under the alternative. The work provides concrete estimator options (KT, Jeffreys mixture, and variants) and demonstrates sequential adaptivity through simulations, showing faster decisions on easier problems and robust asymptotic guarantees without prior knowledge of the alternative. The approach offers a flexible, data-driven framework for rapid anomaly detection in dynamically evolving systems where the null is known but the alternative is composite and unknown.

Abstract

We study the problem of sequentially testing whether a given stochastic process is generated by a known Markov chain. Formally, given access to a stream of random variables, we want to quickly determine whether this sequence is a trajectory of a Markov chain with a known transition matrix $P$ (null hypothesis) or not (composite alternative hypothesis). This problem naturally arises in many engineering problems. The main technical challenge is to develop a sequential testing scheme that adapts its sample size to the unknown alternative. Indeed, if we knew the alternative distribution (that is, the transition matrix) $Q$, a natural approach would be to use a generalization of Wald's sequential probability ratio test (SPRT). Building on this intuition, we propose and analyze a family of one-sided SPRT-type tests for our problem that use a data-driven estimator $\hat{Q}$. In particular, we show that if the deployed estimator admits a worst-case regret guarantee scaling as $\mathcal{O}\left( \log{t} \right)$, then the performance of our test asymptotically matches that of SPRT in the simple hypothesis testing case. In other words, our test automatically adapts to the unknown hardness of the problem, without any prior information. We end with a discussion of known Markov chain estimators with $\mathcal{O}\left( \log{t} \right)$ regret.

Sequential One-Sided Hypothesis Testing of Markov Chains

TL;DR

The paper tackles sequential composite hypothesis testing for Markov chains by extending Wald’s SPRT to a setting with an unknown alternative, using a data-driven estimator to form a likelihood-ratio process. A central idea is to replace the unknown alternative with an estimator whose pointwise log-loss regret is , enabling the test to asymptotically match SPRT performance in the simple case and to yield explicit stopping-time bounds in the Markov case via the stationary-averaged KL divergence . Ville’s inequality ensures type-1 error control, while Markov Wald’s identity facilitates analysis of the stopping time under the alternative. The work provides concrete estimator options (KT, Jeffreys mixture, and variants) and demonstrates sequential adaptivity through simulations, showing faster decisions on easier problems and robust asymptotic guarantees without prior knowledge of the alternative. The approach offers a flexible, data-driven framework for rapid anomaly detection in dynamically evolving systems where the null is known but the alternative is composite and unknown.

Abstract

We study the problem of sequentially testing whether a given stochastic process is generated by a known Markov chain. Formally, given access to a stream of random variables, we want to quickly determine whether this sequence is a trajectory of a Markov chain with a known transition matrix (null hypothesis) or not (composite alternative hypothesis). This problem naturally arises in many engineering problems. The main technical challenge is to develop a sequential testing scheme that adapts its sample size to the unknown alternative. Indeed, if we knew the alternative distribution (that is, the transition matrix) , a natural approach would be to use a generalization of Wald's sequential probability ratio test (SPRT). Building on this intuition, we propose and analyze a family of one-sided SPRT-type tests for our problem that use a data-driven estimator . In particular, we show that if the deployed estimator admits a worst-case regret guarantee scaling as , then the performance of our test asymptotically matches that of SPRT in the simple hypothesis testing case. In other words, our test automatically adapts to the unknown hardness of the problem, without any prior information. We end with a discussion of known Markov chain estimators with regret.
Paper Structure (16 sections, 4 theorems, 29 equations, 2 figures, 1 algorithm)

This paper contains 16 sections, 4 theorems, 29 equations, 2 figures, 1 algorithm.

Key Result

Theorem 1

Given a sequence of i.i.d. observations, this test, using any estimator $\{\hat{q}_t: t \geq 1\}$, has type-1 error at most $\alpha$: Furthermore, if the estimator $\{\hat{q}_t: t \geq 1\}$ has a regret guarantee $r_t = \mathcal{O}\left ( \log{t} \right )$, then we also have

Figures (2)

  • Figure 1: Power of the fixed length test of Wolfer and Kontorovich wolfer2020ergodic, shown by the solid curves, relative to the expected stopping time of our sequential test, marked by the dashed line, with the distribution of stopping times in the background.
  • Figure 2: Average stopping time of our algorithm instantiated with several different estimators for Problem \ref{['eq:toy_problem']} as $\epsilon$ varies.

Theorems & Definitions (11)

  • Definition 1
  • Definition 2
  • Theorem 1
  • Remark 1
  • Theorem 2
  • proof
  • Remark 2
  • Remark 3
  • Remark 4
  • Theorem 3
  • ...and 1 more