The morphology of the ECG waveform varies slightly from beat to beat. Quantification of these changes, in particular within the ST-T segment, has been receiving increasing interest, because electrocardiographic phenomena such as microvolt T wave alternans and augmented QT interval variability have been associated with malignant ventricular arrhythmia in clinical populations as well pro-arrhythmic risk in pharmacological safety testing studies. More recently, P wave variability has received attention by cardiologists due its potential link to atrial fibrillation propensity. Since all those ECG changes are typically very small, high precision as well as robustness of measurement algorithm is of utmost importance for obtaining reliable results.

2DSW concept schematic (Two-dimensional signal warping)
By Martin Schmidt (Own work) [CC BY-SA 4.0], via Wikimedia Commons

The technique proposed in [1] provides a general framework for analysing beat-to-beat changes in ECG waveform and can be utilized for accurately tracking changes in common features of interest, e.g. the P, QRS or QT intervals or amplitude related information. The algorithm first generates a template beat based on ensemble averaging of relatively noise-free beats. Features of interest are annotated on the template in a semi-automated fashion. The template is then adapted to each incoming beat, exploiting a technique called Two-Dimensional Signal Warping (2DSW). In brief, a 2D mesh of warping points is superimposed on the template beat. These warping points are sequentially shifted in x- and y-directions, minimizing the Euclidean distance between segments of the template and the incoming beat. From the optimally adapted template, changes in annotated features can be tracked from beat to beat, providing the foundation for studying ECG variability.

[1] [doi] M. Schmidt, M. Baumert, A. Porta, H. Malberg, and S. Zaunseder, “Two-Dimensional Warping for One-Dimensional Signals—Conceptual Framework and Application to ECG Processing,” IEEE Trans. Signal Process., vol. 62, iss. 21, pp. 5577-5588, 2014.
title = {Two-{Dimensional} {Warping} for {One}-{Dimensional} {Signals}—{Conceptual} {Framework} and {Application} to {ECG} {Processing}},
volume = {62},
issn = {1053-587X},
doi = {10.1109/TSP.2014.2354313},
abstract = {We propose a novel method for evaluating the similarity between two 1d patterns. Our method, referred to as two-dimensional signal warping (2DSW), extends the basic ideas of known warping techniques such as dynamic time warping and correlation optimized warping. By employing two-dimensional piecewise stretching 2DSW is able to take into account inhomogeneous variations of shapes. We apply 2DSW to ECG recordings to extract beat-to-beat variability in QT intervals (QTV) that is indicative of ventricular repolarization lability and typically characterised by a low signal-to-noise ratio. Simulation studies show high robustness of our approach in presence of typical ECG artefacts. Comparison of short-term ECG recorded in normal subjects versus patients with myocardial infarction (MI) shows significantly increased QTV in patients (normal subject 2.36 ms ± 1.05 ms vs. MI patients 5.94 ms ± 5.23 ms (mean ± std), ). Evaluation of a standard QT database shows that 2DSW allows highly accurate tracking of QRS-onset and T-end. In conclusion, the two-dimensional warping approach introduced here is able to detect subtle changes in noisy quasi-periodic biomedical signals such as ECG and may have diagnostic potential for measuring repolarization lability in MI patients. In more general terms, the proposed method provides a novel means for morphological characterization of 1d signals.},
number = {21},
journal = {IEEE Trans. Signal Process.},
author = {Schmidt, M. and Baumert, M. and Porta, A. and Malberg, H. and Zaunseder, S.},
month = nov,
year = {2014},
keywords = {Correlation, Cost function, Dynamic time warping, ECG, Electrocardiography, Heuristic algorithms, Physiology, QT, QT interval, QT variability, signal processing, Signal processing algorithms, two-dimensional warping, Vectors, warping},
pages = {5577--5588},
file = {IEEE Xplore Abstract Record:/Users/martin/Zotero/storage/BYDNA77L/6891378.html:text/html}