[Paper Review] A log-linear time algorithm for constrained changepoint detection
This paper proposes a generalized functional pruning algorithm (GPDPA) for constrained changepoint detection that achieves optimal solutions in log-linear time, $O(Kn\log n)$, by extending Rigaill's functional pruning to affine inequality constraints between adjacent segment means. The method enables fast, accurate peak detection in ChIP-seq data with up-down constraints, outperforming existing state-of-the-art methods in speed and accuracy while maintaining optimality.
Changepoint detection is a central problem in time series and genomic data. For some applications, it is natural to impose constraints on the directions of changes. One example is ChIP-seq data, for which adding an up-down constraint improves peak detection accuracy, but makes the optimization problem more complicated. We show how a recently proposed functional pruning technique can be adapted to solve such constrained changepoint detection problems. This leads to a new algorithm which can solve problems with arbitrary affine constraints on adjacent segment means, and which has empirical time complexity that is log-linear in the amount of data. This algorithm achieves state-of-the-art accuracy in a benchmark of several genomic data sets, and is orders of magnitude faster than existing algorithms that have similar accuracy. Our implementation is available as the PeakSegPDPA function in the coseg R package, https://github.com/tdhock/coseg
Motivation & Objective
- To address the need for fast, optimal changepoint detection under affine constraints in genomic and time series data.
- To overcome the limitations of existing heuristic algorithms like Constrained DPA, which are sub-optimal and quadratic in time complexity.
- To generalize functional pruning techniques to handle arbitrary affine constraints between adjacent segment means.
- To achieve state-of-the-art performance in both speed and accuracy for peak detection in ChIP-seq data.
- To provide a reproducible, open-source implementation via the PeakSegPDPA function in the coseg R package.
Proposed method
- The method uses a generalized functional pruning approach (GPDPA) to solve constrained changepoint detection problems with affine inequality constraints on adjacent segment means.
- It formulates the problem as a dynamic programming optimization over a state space where transitions are governed by constraint functions $g_c$.
- The dynamic programming update rule computes optimal costs $C_{s,t}(u)$ recursively, combining data likelihood and transition costs with penalties.
- A key innovation is the use of constrained cost functions $\text{ConstrainedCost}(C_{\underline{v},t-1})$ to enforce constraints like non-decreasing or up-down patterns.
- The algorithm maintains cost functions as piecewise linear functions, enabling efficient pruning of non-optimal paths.
- Decoding is performed via backtracking to recover the optimal segment means, states, and changepoint locations.
Experimental results
Research questions
- RQ1Can functional pruning be generalized to handle arbitrary affine inequality constraints between adjacent segment means in changepoint detection?
- RQ2Does the proposed GPDPA algorithm achieve optimal solutions with $O(Kn\log n)$ average time complexity under such constraints?
- RQ3How does the performance of GPDPA compare to existing methods in terms of accuracy and speed on real ChIP-seq data?
- RQ4Can the algorithm maintain high accuracy while significantly reducing runtime compared to quadratic-time solvers?
- RQ5Is the functional pruning technique effective for complex constraints such as the up-down pattern in ChIP-seq peak detection?
Key findings
- The proposed GPDPA algorithm achieves $O(Kn\log n)$ average time complexity, matching the best known pruning algorithms but with guaranteed optimality.
- On ChIP-seq data, GPDPA achieves state-of-the-art accuracy in peak detection, outperforming existing methods with similar or better speed.
- Empirical tests show the average number of intervals stored per state is $\log n$, supporting the $O(Kn\log n)$ complexity claim.
- The algorithm is orders of magnitude faster than existing optimal solvers for up-down constrained changepoint detection, while maintaining optimal solution quality.
- The implementation is available as the PeakSegPDPA function in the coseg R package, enabling reproducible research and broad adoption.
- The method successfully generalizes functional pruning to a wide class of affine constraints, including non-decreasing, non-increasing, and up-down patterns.
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.