Vous êtes sur la page 1sur 10

1882 IEEE TRANSACTIONS ON BIOMEDICAL ENGINEERING, VOL. 59, NO.

7, JULY 2012

A Class of Monte-Carlo-Based Statistical Algorithms


for Efficient Detection of Repolarization Alternans
Shahriar Iravanian∗ , Uche B. Kanu∗ , and David J. Christini† , Member, IEEE

Abstract—Cardiac repolarization alternans is an electrophysi- of a few microvolts. MTWA has been closely linked to instances
ologic condition identified by a beat-to-beat fluctuation in action of ventricular fibrillation (VF) and sudden cardiac death (SCD)
potential waveform. It has been mechanistically linked to instances in clinical [1]–[5] and experimental [6]–[8] studies, and recent
of T-wave alternans, a clinically defined ECG alternation in T-wave
morphology, and associated with the onset of cardiac reentry and studies have suggested that it could have added benefit for SCD
sudden cardiac death. Many alternans detection algorithms have risk stratification purposes [9]–[17].
been proposed in the past, but the majority have been designed The low amplitude nature of MTWA makes its detection in
specifically for use with T-wave alternans. Action potential dura- clinical and experimental settings difficult, as the presence of
tion (APD) signals obtained from experiments (especially those de- even the slightest amount of noise can mask and/or mimic an
rived from optical mapping) possess unique characteristics, which
requires the development and use of a more appropriate alternans underlying alternating pattern. Because of this, there have been
detection method. In this paper, we present a new class of algo- various T-wave detection algorithms proposed and utilized in the
rithms, based on the Monte Carlo method, for the detection and past that address this particular challenge [18]–[23] (see [24] for
quantitative measurement of alternans. Specifically, we derive a a review of different alternans detection methodologies).
set of algorithms (one an analytical and more efficient version of T-wave alternans is a manifestation of underlying action po-
the other) and compare its performance with the standard spectral
method and the generalized likelihood ratio test algorithm using tential duration (APD) alternans, which is a beat-to-beat al-
synthetic APD sequences and optical mapping data obtained from ternation in APD and/or morphology expressed at the cellular
an alternans control experiment. We demonstrate the benefits of level [20]. In fact, the potentially causal link between T-wave
the new algorithm in the presence of Gaussian and Laplacian noise alternans and some episodes of VF/SCD has been posited to in-
and frame-shift errors. The proposed algorithms are well suited for clude cellular alternans-APD alternans has been shown to trigger
experimental applications, and furthermore, have low complexity
and are implementable using fixed-point arithmetic, enabling po- reentrant electrical wave activity experimentally and computa-
tential use with implantable cardiac devices. tionally [25]–[27].
Because of the purported importance of APD (also known
Index Terms—Alternans, biomedical signal processing, medical
signal detection, pacemakers. as repolarization) alternans within the context of fibrillation,
there have been a number of studies that focus primarily on
studying its dynamics in experimental settings. Some studies
I. INTRODUCTION have focused on an approach to prevent and/or control cardiac
alternans through the use of externally applied perturbations to
-WAVE alternans is a beat-to-beat oscillation in the ampli-
T tude or morphology of the T wave as seen on the surface
ECG and is typically induced at fast heart rates. Macroscopic
the cardiac tissue [28]–[32].
Experimental research of this type is typically conducted us-
ing transmembrane potential recordings either through the use of
T-wave alternans is rare, and as such, much attention has been microelectrodes [28], [29], [32], or voltage-sensitive fluorescent
dedicated to studying microscopic (i.e., microvolt) T-wave al- dyes (optical mapping) [27], [30]. The same issues that affect
ternans (MTWA), which typically has an amplitude on the order the detection of T-wave alternans are relevant in the study of
APD alternans, namely, the ability for inherently noisy signals
to mask and/or reproduce the characteristics of alternans.
However, algorithms intended for use in detecting MTWA
Manuscript received November 8, 2011; revised January 8, 2012 and Febru- have suboptimal performance when applied to cellular record-
ary 11, 2011; accepted February 28, 2012. Date of publication April 3, 2012;
date of current version June 20, 2012. The work of D. J. Christini was supported
ings [33]. One of the main reasons for this incompatibility relates
by the National Institutes of Health under Grant R01HL094620. Asterisk indi- to the recording lengths typically obtained for each. MTWA
cates co-first authorship. Dagger indicates corresponding author. recordings are generally on the order of minutes (consisting
∗ S. Iravanian is with the Division of Cardiology, Emory University School of
Medicine, Atlanta, GA 30322 USA, and also with The Southeast Permanente
of hundreds of beats) or longer, whereas cellular recordings
Medical Group, Atlanta, GA 30305 USA (e-mail: shahriar.x.iravanian@kp.org). (in particular those using optical mapping signals) are usually
∗ U. B. Kanu is with the Greenberg Division of Cardiology, Weill Cornell Med-
composed of much shorter segments (≈15–30 beats).
ical College, New York, NY 10065 USA (e-mail: ubk2@cornell.edu).
† D. J. Christini is with the Greenberg Division of Cardiology, the De- Another problem that hinders the adoption of previously
partment of Medicine, and the Department of Physiology and Biophysics, developed clinically oriented MTWA algorithms for use with
Weill Cornell Medical College, New York, NY 10065 USA (e-mail: dchristi@ transmembrane signals is the presence and usage of a threshold
med.cornell.edu).
Color versions of one or more of the figures in this paper are available online
parameter. Such ad hoc parameters need extensive experimental
at http://ieeexplore.ieee.org. validation, typically requiring the use of a large set of normal
Digital Object Identifier 10.1109/TBME.2012.2192733 and abnormal subjects. As a result, use of these algorithms for

0018-9294/$31.00 © 2012 IEEE


IRAVANIAN et al.: CLASS OF MONTE-CARLO-BASED STATISTICAL ALGORITHMS FOR EFFICIENT DETECTION 1883

novel signals (e.g., transmembrane potential recordings) would


require an experimental validation step using a large dataset,
which is not readily available. One potential solution is to use
an algorithm with a solid theoretical basis for which the opera-
tional threshold translates into a well-defined statistical test.
In this paper, we present a class of alternans detection algo-
rithms specifically targeted toward APD recordings. As one of
our goals is to enable implantable devices (e.g., pacemakers and
implantable defibrillators) to detect alternans in situ [34], our
algorithms were made to be simple, have low time and space
complexity, and be implementable using integer or fixed-point
arithmetic.
Our method is based on the generation of a random set of
surrogate data derived from the random shuffling of the orig-
inal input (a subtype of the general Monte Carlo simulation
Fig. 1. Half-normal and folded normal distributions. (A) Probability density
technique). In this way, the problem of alternans detection can function of the A i + 1 − A i terms derived from a nonalternating sequence with
be cast as a statistical test comparing the original input and added Gaussian noise. (B) Half-normal distribution (a special case of the folded
the surrogate dataset. A nonparametric version of the proposed normal distribution) is formed by taking the absolute value of each A i + 1 − A i
term derived from (A). (C) One half of the probability density function of the
surrogate-based test has been previously applied successfully A i + 1 − A i terms derived from an alternating sequence with added Gaussian
for detection of MTWA [35]. In contrast, our method is para- noise (half of the bimodal distribution is shown for clarity purposes). (D) Folded
metric in nature, and allows for the estimation of the underly- normal distribution is formed by taking the absolute value of each A i + 1 − A i
term derived from (C) (and from the other half of the bimodal distribution).
ing alternans magnitude and noise level. As will be shown in
Algorithm 2, we derived an analytical solution to the problem
of surrogate generation, which significantly simplified the final
algorithm and improved its time complexity. 3 , H + 4 , · · ·) be such a sequence. As earlier, we have d =
We start by first presenting the method and developing the H − L. It is similar to c with the addition of random Gaussian

alternans detection framework. We discuss two algorithms—the noise , with √ a mean of 0 and a√standard deviation of σ/ 2, i.e.,
first is a more basic algorithm, and is followed by a similar but  = N (0, σ/ 2) (the use of 2 here simplifies the notation in
more efficient version. Next, we apply the algorithm to simulated the following).
APD sequences amidst varying degrees of added realistic noise The effect of the absolute value function is to reflect the neg-
and sample sizes in an effort to probe the specificity (type I error ative part of the distribution (i.e., the collection of individual
rate) and sensitivity (“power”) of our method. We end by using difference terms) over the y-axis. Hence, for sequence d, each
the alternans detection method on experimental data obtained term in the numerator of (1) is from a folded normal distribu-
using fluorescence imaging (via optical mapping techniques). tion [36] [see Fig. 1(D)] with the probability density function,
defined for x ≥ 0, of
1  −(−x−d) 2 /(2σ 2 ) 
+ e−(x−d) /(2σ ) .
2 2

II. METHODS f (x; d, σ) = √ e


σ 2π
Given a sequence a of n positive real numbers Ai representing (2)
APD, we define average alternans magnitude μ(a) as We now introduce the function h(x, y) as

n −1 2 −x 2 /(2y 2 ) x
|Ai+1 − Ai | h(x, y) = y e + x erf( √ ) (3)
μ(a) = i=1 . (1) π y 2
n−1
in which erf is the error function
Note that, for practical application purposes, the source is a  x
2
e−t dt.
2
time series of recorded signals, which needs to be first prepro- erf(x) = √ (4)
cessed before being reduced to a set of measurements suitable π 0
for inclusion in a. Integrating (2), we can show that the expected value of μ(d) is
First, consider the trivial sequence, b = (L, L, . . . , L). This  ∞
sequence does not exhibit any alternans; hence, μ(b) = 0. Now, E[μ(d)] = xf (x; d, σ)dx (5)
compare this to the sequence c = (L, H, L, H, . . .), which rep- 0
resents an ideal alternating sequence (i.e., constant alternans and = h(d, σ). (6)
no noise), where d = H − L. Here, each term in the numerator
of (1) is equal to d; therefore, μ(c) = d. The nonalternating sequence e = (L + 1 , L + 2 , · · · , L +
However, true alternans is not the only factor that can affect n ) is a special case and forms a half-normal distribution [see
the average alternans magnitude—random noise has a similar Fig. 1(B)]. The expected value of μ(e) is calculated as
 ∞
effect. Let us turn our attention to a realistic alternating sequence
that is contaminated with noise. Let d = (L + 1 , H + 2 , L + E[μ(e)] = xf (x; 0, σ)dx (7)
0
1884 IEEE TRANSACTIONS ON BIOMEDICAL ENGINEERING, VOL. 59, NO. 7, JULY 2012

= h(0, σ) (8) A. Algorithm 1: Monte Carlo Simulation



2 The first algorithm is conceptually the simplest one; however,
= σ. (9) its time complexity is not optimal. The basic idea is to explicitly
π
calculate μ0 , starting from (11), but instead of generating all n!
In this paper, our main goal is to describe a simple and robust permutations of the original sequence, we settle for a random
method to estimate d and σ (either implicitly or explicitly), subset of permutations. Specifically, for a given input sequence
given an unknown sequence x, and to determine whether the a, we calculate the mean alternans magnitude μ̂ = μ(a). Next,
calculated d reaches statistical significance (i.e., is consistent we generate m different random permutations (π1 to πm ) of a
with the existence of true underlying alternans). In particular, we and calculate the mean alternans magnitude for each permuta-
seek a method that does not require finding an explicit solution tion. In this way, we make the following assumption:
to (3).
1 
m
While a realistic sequence may not be exactly modeled as
μ0 = μ(πi (a)). (14)
d, it nevertheless provides a good starting point. One needs to m i=1
calculate two parameters in order to estimate d and σ. The first is
simply the average alternans magnitude of the original sequence, We estimate the noise level and the z-score using (12) and (13),
μ̂ = μ(x). The second parameter is introduced as follows. The respectively, and alternans is detected in a if z > z0 , where z0
key to differentiating an alternating sequence from a sequence is a preset cutoff value.
with added noise but no alternans is the observation that the Moreover, we can estimate d by solving μ̂ = h(d, σ). One
apparent average alternans is dependent (independent) on the useful
 shortcut stems from the observation that h(x, y) ≈
order of elements in the former (latter). x2 + y 2 . Hence
Let πk (x) be a random permutation of x, i.e., a sequence com- 
d ≈ μ̂2 − σ 2 . (15)
posed of the same values as x but in a random order. Assuming
that x has the same dynamics as d, on average each member L Caution has to be practiced when generating random permu-
of πk (x) will be adjacent to one L and one H. Similarly, each tations of a sequence to avoid introducing bias into the process.
H will be adjacent to one H and one L. Hence, the distribu- An efficient and proven method, such as the Knuth–Fisher–
tion of the random variable Xi = |Ai+1 − Ai | for Ai ∈ πk (x) Yates shuffling algorithm [37], ensures the randomness of the
exhibits a probability density function which is a combination resulting sequences.
of those derived from e and d, i.e., (f (x; 0, σ) + f (x; d, σ))/2. Algorithm 1 is simple to implement; however, its performance
Therefore is suboptimal. Its time complexity is O(nm), where n is the
h(0, σ) + h(d, σ) number of elements in a and m ≤ n! is the number of permu-
E[X] = . (10) tations generated. In general, calculating μ0 accurately requires
2
m n. Fortunately, as described in the following, it is possi-
Let us now define ble to improve this complexity by calculating μ0 analytically in
1  O(n · log(n)).
μ0 = μ(πk (x)) (11)
n!
k
B. Algorithm 2: Analytic Monte Carlo (AMC)
the summation of which occurs over all possible permutations
of x. Under this condition, we expect that μ0 approaches E[X]. The goal here is to improve on the time complexity of Al-
Accepting this assumption as valid and using (6) and (9), we gorithm 1 by deriving an analytical form for μ0 . We define
can derive the following equation: the rank K(i) of an element Ai of the input sequence a equal
 to its index if a is sorted in a nondescending order. For ex-
σ=
π
(2μ0 − μ̂). (12) ample, if a = {50, 55, 49, 54, 57, 52}, then K(2) =5, since the
2 index of the second element (55) in the sorted input sequence
In this way, μ0 provides the second parameter for estimating d {49, 50, 52, 54, 55, 57} is equal to 5. As shown in Appendix A,
(to be shown shortly hereafter in Section II-A) and σ. The basic the closed form of μ0 can be represented as
idea for the detection algorithms discussed in the following is 2  n

that if x is in fact alternating, then μ̂ will be significantly different μ0 = (2K(i) − n − 1)Ai . (16)
n(n − 1) i=1
from μ0 . In order to test this, we define the null hypothesis as
H0 : μ̂ = μ0 . We will derive the formula for the standard error √ This equation forms the basis for the AMC algorithm. Given
of μ0 in the discussion of Algorithm 2 and will show that σ/ n a, we first find μ̂ = μ(a). Then, a is sorted to find the rank
is a good approximation. Hence, we can calculate the z-score as of each item. Next, (16) is used to calculate μ0 . Finally, the
μ̂ − μ0 algorithm continues similarly to Algorithm 1 by calculating the
z= √ . (13) z-score and comparing it to the cutoff value. AMC has a time
σ/ n
complexity of O(n · log(n)), resulting from the sorting stage.
The rejection of H0 , based on a prechosen z-score cutoff, is Equation (16) is also the basis for finding the standard error
indicative of alternans being present with the corresponding of μ0 . Let D = {d1 , d2 , . . .} be a set of sequences generated
level of statistical significance. according to the same dynamics as d. Our goal is to find the
IRAVANIAN et al.: CLASS OF MONTE-CARLO-BASED STATISTICAL ALGORITHMS FOR EFFICIENT DETECTION 1885

standard deviation of a set whose elements are μ(dj ), which


is equal to the standard error of the estimation of μ(d). Under
these conditions, we may assume that each Ai is an independent
random
√  the samestandard deviation as , i.e.,
variable with
σ/ 2. Since Var( i αi Xi ) = i αi2 Var(Xi ) for independent
random variables Xi and constant αi , we have

2 n
Var(μ0 ) = Var (2K(i) − n − 1)Ai (17)
n(n − 1) i=1
n

4 
= 2 (2K(i) − n − 1)2 Var(Ai )
n (n − 1)2 i=1
(18)
2σ 2 n
= (2i − n − 1)2 (19)
n2 (n − 1)2 i=1

2σ 2 n(n − 1)(n + 1) Fig. 2. Histogram showing the noise estimation of the AMC algorithm in
= (20) response to pure Gaussian noise inputs (N (0, 1)). A total 50 000 input sequences
− 1)2
n2 (n 3 of length n =64 were fed into the√algorithm and the noise was estimated using
2(n + 1) 2 √mean is σ = 1.4136 ≈ 2. The standard deviation of the distribution
(12). The
= σ . (21) is ≈ σ/ n.
3n(n − 1)
 
The transition from ni=1 K(i) to ni=1 i is valid because for
1 ≥ i ≥ n, {K(i)} is just a permutation of {1, . . . , n}. We can
calculate the standard error as spectral method (SM) widely used in practice [21] and a gener-
alized likelihood ratio test (GLRT) method [38], [39].
2(n + 1) Fig. 2 depicts a histogram showing the distribution of the
σ(μ0 ) = σ (22)
3n(n − 1) noise estimation [i.e., σ in (12)] by the AMC algorithm when it
 is fed a nonalternating sequence with Gaussian noise, similar √ to
≈σ
2
(23) sequence e with  = N (0, 1). As expected, the mean is ≈ 2.
3n To implement SM, we applied a Hamming window to the
σ input sequence followed by a fast Fourier Transform. The al-
≤√ if n ≥ 5. (24)
n ternans ratio k was defined as the ratio of the spectral power at
0.5f to the mean noise power (measured in the 0.4f–0.45f win-
The last approximation is used in Algorithms 1 and 2. It is a
dow). We implemented the Laplacian noise-optimized variant
conservative approximation
 that overestimates the true value of
of the GLRT algorithm (also called GLRT-L) [40]. For an input
σ(μ0 ) by a factor of 3/2 = 1.224745.
sequence x = {X1 , X2 , . . . , Xn }, GLRT was calculated by de-
The detailed derivation of (16) is presented in Appendix A.
trending the data and subtracting the mean, Yi = Xi − X, and
A sketch of the proof follows here. Assume that we generate
then negating the values at the odd indices, Zi = (−1)i Yi . Let
all n! different permutations of a and add the corresponding n
Z0 = median i=1 (Zi ). The GLRT output parameter was calcu-
μ(πk (a)), for 1 ≤ k ≤ n!. The summation has (n − 1)n! terms
lated as l = ni=1 (|Zi | − |Zi − Z0 |)/C, where C is a constant
of the form |Ai − Aj | (note that the indices point to the position
proportional to the baseline noise.
of each element in the original sequence a). Now, we can convert
Sequences of APD values were simulated with a known “true”
|Ai − Aj | to Ai − Aj if Ai > Aj ; otherwise, it can be converted
alternans magnitude (i.e., d) and three different types of added
to Aj − Ai . Each element Ai participates in k = 2(n − 1)!(n −
noise. First, we tested sequences with varying amounts√of added
1) terms. In each term, it has a plus sign if it is larger than
random Gaussian white noise (with rms power of σ/ 2). The
Aj , which happens with a probability of (K(i) − 1)/(n − 1),
signal-to-noise ratio (SNR) was defined as d/σ. For each SNR,
and a minus sign if it is smaller than Aj with a probability of
5000 sequences were generated and subjected to the AMC, SM,
(n − K(i))/(n − 1). Hence, the coefficient of Ai in the final
and GLRT algorithms. For each algorithm, a receiver operating
sum is proportional to 2K(i) − n + 1. The rest of the proof
characteristic (ROC) curve was derived by varying a threshold
deals with finding the correct normalization factor.
parameter and finding the detection rate for the given threshold
among the 5000 generated sequences (sensitivity) and among
III. RESULTS
a matched set of 5000 generated sequences with no alternans
In this section, we present the simulation-derived perfor- (1-specificity). For a given threshold t, the detection rate was the
mance results of the AMC algorithm. First, we explore the re- ratio of sequences with the output parameter (z for AMC, k for
sponse of the algorithm to pure noise input. Next, we compare SM, and l for GLRT) greater than t. Fig. 3(A) includes the ROC
the performance of the AMC algorithm to that of a standard results for SNR = 1. In this case, AMC and SM were similar,
1886 IEEE TRANSACTIONS ON BIOMEDICAL ENGINEERING, VOL. 59, NO. 7, JULY 2012

Fig. 4. ROC contours (Laplacian noise) comparing AMC, SM, and GLRT
algorithms for a range of SNR and the expected frame shift numbers. The red
Fig. 3. AMC, SM, and GLRT ROC curves under (A) and (C) Gaussian and curve is for a sequence length of n =24, green is for n =32, and blue is for
(B) and (D) Laplacian noise (sequence length = 32, SNR = 1). A–B: absence n =48. Contour lines denote equivalence between AMC and GLRT algorithms
of frame shift noise; C–D: frame shift noise probability = 0.1. (in term of AUC equivalence). Each area is marked by the algorithm which has
superior performance therein (as measured by AUC). SM algorithm was not
superior in any point and has no designated area in this figure.
while GLRT had a better performance. Here, the performance
was defined as the area under the ROC curve (AUC).
The second type of noise was Laplacian (with a double ex- rithm based on the AUC calculated from 20 000 generated se-
ponential probability distribution), which has been proposed as quences. Fig. 4 shows that GLRT was the optimal algorithm for
a more realistic model of ECG noise [39]. Fig. 3(B) shows low SNR/low frame shift points, whereas AMC performed bet-
the ROC curve for the three algorithms applied to random al- ter for points with higher SNR and larger frame shift numbers.
ternating sequences with added Laplacian noise (SNR = 1). SM performance was generally in the middle and not optimal
As earlier, AMC and SM were similar, whereas GLRT outper- for any point; hence, no SM region is shown in the graph.
formed both, albeit to a greater extent. This result is consistent In order to further probe the functionality of each algorithm
with the fact that the GLRT method is based on a maximum under frame shift noise, we tested sequences of different lengths
likelihood estimator that assumes Laplacian noise. (2r , for 4≤ r ≤8) and added random Gaussian white noise (SNR
The third type of added noise relates to frame-shift errors, = 3). As earlier, for each set of parameters, 5000 sequences were
which occur commonly in real signals. Some possible causes for generated and subjected to AMC, SM, and GLRT. A detection
frame-shift errors are alternans phase reversal, transient episodes rate was calculated in each case [see Fig. 5(A)–(C)]. The detec-
of alternans in the same sequence, ectopic beats, and spuri- tion rate was the probability that the target algorithm returned
ous beat detection. For example, given an alternating sequence true. For AMC, a positive detection was defined as z > 2; for
{L, H, L, H, . . .}, a frame-shift error can result in a sequence SM, positive detection corresponded to k > 3 (according to
of the form (. . . , L, H, H, L . . .) or (. . . , H, L, L, H, . . .). For standard practice); similarly, for GLRT, positive detection cor-
an input sequence x, the shift probability ps is defined as the responded to l > 3.
probability of a frame shift for any two consecutive elements, As expected, for all three algorithms, the detection rate in-
Xi , Xi+1 . creased for longer sequences. For short sequences (n ≈ 16),
Fig. 3(C) and (D) compares the performance of the three algo- all three algorithms showed great sensitivity to frame-shift
rithms applied to sequences with a 0.1 frame shift probability (C: errors. For longer sequences, the detection rate of SM and
with added Gaussian noise, SNR = 1; D: with added Laplacian GLRT improved slightly and approached a limiting curve [see
noise, SNR = 1). Particularly, under Gaussian noise conditions, Fig. 5(B)and (C)], whereas AMC showed continuing improve-
the GLRT algorithm was very sensitive to frame shift noise and ment [see Fig. 5(A)].
its performance degraded with even a small shift probability. Fig. 6 demonstrates how the algorithm can be used to de-
The AMC method was mostly resistant to frame-shift errors, tect alternans in experimental data (in this case, transmem-
while SM performance was in the middle. brane fluorescence optical mapping recordings were used). The
Fig. 4 shows ROC comparisons amongst the AMC, SM, and experimental setup was described previously [30]. In brief, arte-
GLRT algorithms for a range of sequence lengths, Laplacian rially perfused canine right ventricular preparations were stained
noise, and the expected numbers of frame-shift errors in a given with a voltage-sensitive fluorescent dye. Linear high spatial res-
sequence nps where n is the sequence length and ps is the shift olution optical mapping images were obtained from the endo-
probability. For each data point, we determined the best algo- cardial surface by a line-scan charge-coupled device camera.
IRAVANIAN et al.: CLASS OF MONTE-CARLO-BASED STATISTICAL ALGORITHMS FOR EFFICIENT DETECTION 1887

Fig. 6. Alternans detection applied to optical mapping data. AMC and (15)
were used on action potential sequences (22 APDs) derived from a 2.75 cm
region of cardiac tissue during an alternans control experiment. The alternans
control sequence was off(blue)–on(green)–off(red), and the resulting (A) z-
scores and (B) d-values (i.e., estimated underlying alternans magnitude) that
were calculated at each point are shown. (z-score >2 indicates alternans is
present). (C) Transmembrane fluorescence signal from the site of electrode
stimulation and the resulting APD values shown above [data used in that of the
blue trace in (A) and (B)].

After realtime processing, the data were reduced to 128 chan-


nels. A span of the recording line ≈2.75 cm in length is depicted
in Fig. 6(A) and (B). The channel located at 0 was fed to a real-
time control system implementing the adaptive diastolic interval
algorithm [31], which modulated the timing of the pacemaker
spikes to suppress alternans. Three sequential recordings were
processed using AMC [see Fig. 6(A) and (B)]. The first record-
ing (blue trace) shows how static (control-off) pacing induced
alternans. A segment of the recorded signal at the control chan-
nel and the measured APDs is shown in Fig. 6(C). There was
clear alternans, both visually, and as detected by AMC. Note
that discordant alternans was induced in this example, hence the
presence of areas of reduced alternans (nodes). In the second
recording (green trace), an alternans control pulse sequence was
successfully applied at the proximal end of the tissue and elimi-
nated alternans as was reflected in the spatially extended z-score
computed. Example three (red trace) shows the reversion back
to alternans when static pacing was resumed.

Fig. 5. AMC, SM, and GLRT detection rates, given varying levels of frame IV. DISCUSSION
shift probability and varying sequence lengths (SNR = 3; Gaussian noise).
Varying amounts of frame shift noise were added to sequences (L = 16, 32, 64, In this paper, we present a new class of algorithms for the
128, and 256) of synthetic APD alternans data. The detection rate is how often
(A) AMC, (B) SM, and the (C) GLRT method identified the resulting sequence
detection and measurement of alternans in generic sequences.
as one with underlying alternans (5000 sequences were simulated for each data We further provide an analytical solution (AMC) that negated
point). the need to explicitly generate a large number of random test
1888 IEEE TRANSACTIONS ON BIOMEDICAL ENGINEERING, VOL. 59, NO. 7, JULY 2012

sequences and one which posses near-optimal time complex- numerically stable and can be implemented using fixed-point
ity. Additionally, we tested the noise (Gaussian, Laplacian, and arithmetic.
frame shift) and sequence length sensitivity of the algorithm Another advantage of the presented algorithms is that its out-
and compared its performance with that of the SM and GLRT put is expressed in terms of a z-score, which can then be tested
methods. Finally, we applied our algorithm to actual signals and understood using standard statistical methodology. This fea-
obtained during optical mapping, and in doing so showed their ture is particularly useful in the case of novel signals, such
applicability in real experiments. as optical recordings, for which the algorithm is not validated
Over the last 25 years, many different algorithms and methods formally.
have been proposed for alternans detection [24], so many that The ability to detect and quantify experimentally observed
one may wonder what the incentive for the development of alternans is particularly useful when trying to better understand
yet another algorithm might be. It should be noted that various the dynamics of alternans and its relationship with reentrant
algorithms for alternans detection cannot be simply ranked on wave formation and VF initiation. Although recent studies have
an absolute scale as better or worse—each algorithm has specific aimed to uncover the dynamics of alternans initiation, the mech-
advantages and disadvantages. anisms(s) are not completely understood (especially for discor-
In choosing a particular algorithm for a given detection task, dant alternans initiation). Subtle changes in pacing rate [42],
one should take into consideration the specific nature of the input ectopic beat activity [43], and conduction-velocity/APD resti-
signal, including the expected alternans amplitude, the type and tution [44] interactions may all play a role. These dynamical
magnitude of the noise, availability of multiple correlated input transitions often occur very close to the system’s bifurcation in-
channels,1 and the duration of the input signal in addition to stability point, during periods of small alternans magnitude, and
computational constraints (processor speed, available memory, given the inherently imperfect nature of transmembrane voltage
presence of a hardware floating point unit, online versus offline measurements (of which optical mapping is a prime example),
computation). these conditions can be difficult to analyze. Moreover, many of
Most alternans detection algorithms have been designed and these phenomena are transient and require the ability to detect
validated for the detection of MTWA; thus, they are geared alternans, given a short segment of the data. Experiment-tailored
toward relatively low SNR signals and long sequences that are statistical tools could also aid in better understanding the dynam-
primarily contaminated with Gaussian or Laplacian noise. On ics of wave propagation conduction block [26], [27], [42]–[44]
the other hand, our primary motivation in developing this new and the genesis of spiral waves (and wavelets) [45], [46].
class of algorithms was the detection of alternans in optically In general, successful alternans detection requires careful at-
recorded signals. The particular characteristics of optical signals tention to the characteristics of the input signal, the external
are relatively large SNR (≥1), short sequence lengths (≈15–30 constraints of the system, and the nature of the desired output.
beats), and the additional presence of non-Gaussian noise (i.e., The algorithms described in this paper, especially the implicit
frame-shift errors). In addition, as was shown in Section III, form formulated in AMC, provide investigators with an addi-
these new algorithms have near-optimal performance for this tional tool to perform this task and may in fact be optimal for a
class of signals. certain class of input signals.
The source of frame shift or phase errors depends on the
particular type of the input signal. For detection of MTWA in APPENDIX A
surface ECG signals, premature ventricular beats or runs of
ventricular tachycardia introduce frame-shift error. Typically, PROOF OF THE CORRECTNESS OF ALGORITHM 2
input signals with even a modest burden of premature beats In this appendix, we prove (16), which is
are excluded from MTWA analysis. The use of a method that
is (partially) resistent to frame-shift errors expands the range 2  n

of acceptable inputs. In this paper, our experimental focus was μ0 = μ(a) = (2K(i) − n − 1)Ai (25)
n(n − 1) i=1
on optically recorded transmembrane potentials, for which mis-
detection of action potentials may result in frame-shift error. where a is the input sequence of n elements and K(i) is the
Another source of phase error is the presence of two or more rank function defined in Algorithm 2. The starting point is the
intervals of transient alternans in the input signal, which can definition of the absolute value function
occur in both surface and intracardiac signals.
A secondary motivation was the development of an algorithm |Ai − A − j| = βij (Ai − Aj ) (26)
that can be easily implemented in an implanted device like a
pacemaker or an implantable cardioverter-defibrillator, which where
imposes severe constraints on the time and space complexity
+1 if Ai > Aj or (Ai = Aj and i > j)
allowable. AMC fulfills this condition because not only does βi j = (27)
it posses favorable time and space complexity, but also it is −1 if Ai < Aj or (Ai = Aj and i < j).

The reason for assigning β =1 or β = −1 instead of β =0 in the


1 The alternans detection algorithm can include multiple input channels in its equal cases is to enforce a strict ordering on Ai to simplify the
analysis to enhance the accuracy of detection (multilead analysis) [41]. following discussion (see in the following). Substituting (26)
IRAVANIAN et al.: CLASS OF MONTE-CARLO-BASED STATISTICAL ALGORITHMS FOR EFFICIENT DETECTION 1889

into (1) The probability that αi = 0 is 1 − P (α = +1) − P (α =


−1) − P (α = +2) − P (α = −2). In summary
n −1
1  ⎧
μ(a) = |Ai − Aj | (28) ⎪ 2li
n − 1 i=1 ⎪
⎪ x = +1

⎪ n(n − 1)



n −1
 ⎪
⎪ 2ri
1 ⎪
⎪ x = −1
= −β21 A1 + βn ,n −1 + (βi,i−1 − βi+1,i )Ai ⎪
⎪ n(n − 1)
n−1 ⎪

i=2 ⎪
⎨ l (l − 1)
i i
(29) P (αi = x) = x = +2

⎪ n(n − 1)
 ⎪

n

=
1
αi Ai (30) ⎪ ri (ri − 1)

⎪ x = −2
n−1 ⎪
⎪ n(n − 1)


i=1



where αi is an integer between −2 to +2, depending only on ⎩ n(n − 1) − li (li + 1) − ri (ri + 1) x = 0.

n(n − 1)
whether Ai is smaller or larger than its neighbor(s). (38)
In Algorithm 1, we generated m distinct permutations of a. By definition, we have
Here, we consider all m! possible permutations. We can write
αi = P (αi = +1) − P (αi = −1) + 2P (αi = +2)
1 
n
μ(a) = αi Ai . (31) − 2P (αi = −2). (39)
n − 1 i=1
Simplifying
Here, αi is the average value of αi over all the permutations.
Let us define li and ri 2(li − ri )
αi = . (40)
n
li = ord{Aj |Aj < Ai } (32) Note that we used li + ri = n − 1 in simplification. Substituting
back into (31) we obtain the equation to calculate μ(a)
and
2  n

ri = ord{Aj |Aj > Ai }. (33) μ(a) = (li − ri )Ai . (41)


n(n − 1) i=1
In other words, li is the number of items in a which are
We have li = K(i) − 1 and ri = n − K(i) (see the definition
smaller than Ai , whereas ri is the number of items which are
of K(i) in Algorithm 2). Because of the strict ordering enforced
larger. Now, considering all the permutations, the probability
by (26), these equations remain valid even if multiple elements
that Ai is at one end of a permutation is 2/n, and the probability
of a have the same numerical value. Replacing li and ri , we
that Ai is larger than its neighbor is li /(n − 1); hence,
obtain (25).
2li
P (αi = +1) = (34) APPENDIX B
n(n − 1)
ALGORITHM CODE
where P (S) stands for the probability of the statement S being
true. Similarly

2ri
P (αi = −1) = (35)
n(n − 1)

To find the probability of αi = +2, we multiply the probabil-


ity that Ai is not at one end of the permutation (n − 2)/n by the
probability of Ai being larger than or equal to its two neighbors
l i (l i −1)
(n −1)(n −2) to obtain

li (li − 1)
P (αi = +2) = . (36)
n(n − 1)

Again

ri (ri − 1)
P (αi = −2) = . (37)
n(n − 1)
1890 IEEE TRANSACTIONS ON BIOMEDICAL ENGINEERING, VOL. 59, NO. 7, JULY 2012

[13] R. L. Verrier, K. Kumar, and B. D. Nearing, “Basis for sudden cardiac


death prediction by T-wave alternans from an integrative physiology per-
spective,” Heart Rhythm, vol. 6, no. 3, pp. 416–422, Mar. 2009.
[14] R. L. Verrier, B. D. Nearing, and K. F. Kwaku, “Noninvasive sudden death
risk stratification by ambulatory ECG-based T-wave alternans analysis:
Evidence and methodological guidelines,” Ann. Noninvas. Electrocar-
diol., vol. 10, no. 1, pp. 110–120, Jan. 2005.
[15] S. M. Narayan, “T-Wave alternans and the susceptibility to ventricular
arrhythmias,” J. Amer. College Cardiol., vol. 47, no. 2, pp. 269–281, Jan.
2006.
[16] S. M. Narayan, “T-wave alternans testing for ventricular arrhythmias,”
Progr. Cardiovasc. Diseases, vol. 51, no. 2, pp. 118–127, Sep. 2011.
[17] S. M. Narayan, M. R. Franz, P. Clopton, E. J. Pruvot, and D. E. Krummen,
“Repolarization alternans reveals vulnerability to human atrial fibrilla-
tion,” Circulation, vol. 123, pp. 2922–2930, Jun. 2011.
[18] L. Burattini and W. Zareba, “Time-domain analysis of beat-to-beat vari-
ability of repolarization morphology in patients with ischemic cardiomy-
opathy,” J. Electrocardiol., vol. 32, pp. 166–172, Jan. 1999.
[19] L. Burattini, W. Zareba, and R. Burattini, “Adaptive match filter based
method for time vs. amplitude characterization of microvolt ECG T-
wave alternans,” Ann. Biomed. Eng., vol. 36, no. 9, pp. 1558–1564, Sep.
2008.
[20] P. Laguna, G. B. Moody, J. Garca, A. Goldberger, and R. Mark, “Analysis
of the ST-T complex of the electrocardiogram using the Karhunen–Love
transform: Adaptive monitoring and alternans detection,” Med. Biol. Eng.
Comput., vol. 37, no. 2, pp. 175–189, Mar. 1999.
REFERENCES [21] J. M. Smith, E. A. Clancy, C. R. Valeri, J. Ruskin, and R. Cohen, “Electrical
[1] A. Armoundas, M. Osaka, T. Mela, D. S. Rosenbaum, J. N. Ruskin, alternans and cardiac electrical instability,” Circulation, vol. 77, no. 1,
H. Garan, and R. J. Cohen, “T-wave alternans and dispersion of the QT pp. 110–121, Jan. 1988.
interval as risk stratification markers in patients susceptible to sustained [22] P. Strumillo and J. Ruta, “Poincar mapping for detecting abnormal dy-
ventricular arrhythmias,” Amer. J. Card., vol. 82, no. 9, pp. 1127–1129, namics of cardiac repolarization,” IEEE Eng. Med. Biol. Mag., vol. 21,
Nov. 1998. no. 1, pp. 62–65, Jan. 2002.
[2] M. Gold, D. Bloomfield, K. Anderson, N, El-Sherif, D. J. Wilber, [23] A. Maybhate, S. C. Hao, S. Iwai, J. U. Lee, A. B. Guttigoli, K. M. Stein,
W. J. Groh, N. A. Estes, E. S. Kaufman, M. L. Greenberg, and D. S. Rosen- B. B. Lerman, and D. J. Christini, “Detection of repolarization alternans
baum, “A comparison of T-wave alternans, signal averaged electrocar- with an implantable cardioverter defibrillator lead in a porcine model,”
diography and programmed ventricular stimulation for arrhythmia risk IEEE Trans. Biol. Eng., vol. 52, no. 7, pp. 1188–1194, Jul. 2005.
stratification,” J. Amer. College Card., vol. 36, no. 7, pp. 2247–2253, [24] J. P. Martinez and S. Olmos, “Methodological principles of T wave alter-
2000. nans analysis: A unified framework,” IEEE Trans. Biomed. Eng, vol. 52,
[3] S. Hohnloser, T. Klingenheben, Y. Li, M. Zabel, J. Peetermans, and no. 4, pp. 599–613, Apr. 2005.
R. J. Cohen, “T wave alternans as a predictor of recurrent ventricular [25] J. Pastore, S. Girouard, K. Laurita, F. Akar, and D. S. Rosenbaum, “Mech-
tachyarrhythmias in ICD recipients: Prospective comparison with con- anism linking T-wave alternans to the genesis of cardiac fibrillation,”
ventional risk markers,” J. Card. Electrophys., vol. 9, pp. 1258–1268, Circulation, vol. 99, no. 10, pp. 1385–1394, 1999.
1998. [26] J. Fox, M. Riccio, F. Hua, E. Bodenschatz, and R. F. Gilmour Jr., “Spa-
[4] T. Klingenheben, M. Zabel, R. D’Agostino, R. J. Cohen, and S. H. Hohn- tiotemporal transition to conduction block in canine ventricle,” Circulat.
loser, “Predictive value of T-wave alternans for arrhythmic events in pa- Res., vol. 90, no. 3, pp. 289–296, Jan. 2002.
tients with congestive heart failure,” Lancet, vol. 356, no. 9230, pp. 651– [27] J. Pastore and D. Rosenbaum, “Role of structural barriers in the mechanism
652, Aug. 2000. of alternans-induced reentry,” Circulat. Res., vol. 87, no. 12, pp. 1157–
[5] D. Rosenbaum, L. Jackson, J. Smith, H. Garan, J. N. Ruskin, and R. J. Co- 1163, 2000.
hen, “Electrical alternans and vulnerability to ventricular arrhythmias,” [28] G. Hall and D. Gauthier, “Experimental control of cardiac muscle alter-
New Engl. J. Med., vol. 330, no. 4, pp. 235–241, Jan. 1994. nans,” Phys. Rev. Lett., vol. 88, no. 19, 198102, Apr. 2002.
[6] M. Chinushi, D. Kozhevnikov, E. B. Caref, M. Restivo, and N. El-Sherif, [29] S. Gaeta, G. Bub, G. Abbott, and D. J. Christini, “Dynamical mechanism
“Mechanism of discordant T wave alternans in the in vivo heart,” J. Card. for subcellular alternans in cardiac myocytes,” Circulat. Res., vol. 105,
Electrophys., vol. 14, no. 6, pp. 632–638, Jun. 2003. pp. 335–342, Jul. 2009.
[7] M. Chinushi, M. Restivo, E. B. Caref, and N. El-Sherif, “Electrophys- [30] U. B. Kanu, S. Iravanian, R. F. Gilmour, and D. J. Christini, “Control of
iological basis of arrhythmogenicity of QT/T alternans in the long-QT action potential duration alternans in canine cardiac ventricular tissue,”
syndrome: Tridimensional analysis of the kinetics of cardiac repolariza- IEEE Trans. Biomed. Eng., vol. 58, no. 4, pp. 894–904, Apr. 2011.
tion,” Circulat. Res., vol. 83, no. 6, pp. 614–628, Sep. 1998. [31] P. N. Jordan and D. J. Christini, “Adaptive diastolic interval control of car-
[8] W. Shimizu and C. Antzelevitch, “Cellular and ionic basis for T-wave al- diac action potential duration alternans,” J. Cardiovasc. Electrophysiol.,
ternans under long-QT conditions,” Circulation, vol. 99, no. 11, pp. 1499– vol. 10, pp. 1177–1185, Oct. 2004.
1507, Mar. 1999. [32] D. Christini, M. Riccio, C. Culianu, J. Fox, A. Karma, and R. F. Gilmour,
[9] N. El-Sherif, G. Turitto, R. P. Pedalino, and D. Robotis, “T-wave alternans Jr., “Control of electrical alternans in canine cardiac purkinje fibers,”
and arrhythmia risk stratification,” Ann. Noninvas. Electrocard., vol. 6, Phys. Rev. Lett., vol. 96, no. 10, 104101, 2006.
no. 4, pp. 323–332, Oct. 2001. [33] Z. Jia, H. Bien, and E. Entcheva, “Detecting space-time alternating bio-
[10] T. Chow, D. J. Kereiakes, C. Bartone, T. Booth, E. Schloss, T. Waller, logical signals close to the bifurcation point,” IEEE Trans. Biomed. Eng.,
E. Chung, S. Menon, B. Nallamothu, and P. S. Chan, “Prognostic utility of vol. 57, no. 2, pp. 316–324, Feb. 2010.
microvolt T-wave alternans in risk stratification of patients with ischemic [34] D. J. Christini and B. B. Lerman, “Implantable cardioverter-defibrillator
cardiomyopathy,” J. Amer. College Card., vol. 47, no. 9, pp. 1820–1827, detection of repolarization alternans: Uncovering a marker of electrical
May 2006. instability,” Heart Rhythm, vol. 3, no. 7, pp. 798–799, Jul. 2006.
[11] G. Turitto, E. B. Caref, G. El-Attar, M. Helal, A. Mohamed, R. Pedalino, [35] S. Nemati, O. Abdala, V. Monasterio, S. Yim-Yeh, A. Malhotra, and
and N. El-Sherif, “Optimal target heart rate for exercise-induced T-wave G. D. Clifford, “A nonparametric surrogate-based test of significance for
alternans,” Ann. Noninvas. Electrocardiol., vol. 6, no. 2, pp. 123–128, T-wave alternans detection,” IEEE Trans. Biomed. Eng., vol. 58, no. 5,
Apr. 2001. pp. 1356–1364, May 2011.
[12] D. M. Bloomfield, T. Bigger, R. C. Steinman, P. Namerow, M. Parides, [36] F. C. Leone, R. B. Nottingham, and L. S. Nelson, “The folded normal
A. B. Curtis, E. S. Kaufman, J. Davidenko, T. Shinn, and J. Fontaine, distribution,” Technometrics, vol. 3, no. 4, pp. 543–550, 1961.
“Microvolt T-wave alternans and the risk of death or sustained ventricular [37] D. E. Knuth, The Art of Computer Programming: Seminumeri-
arrhythmias in patients with left ventricular dysfunction,” J. Amer. College cal Algorithms. vol. 2, Reading, MA: Addison-Wesley, 1969, pp.
Cardiol., vol. 47, no. 2, pp. 456–463, Jan. 2006. 124–125.
IRAVANIAN et al.: CLASS OF MONTE-CARLO-BASED STATISTICAL ALGORITHMS FOR EFFICIENT DETECTION 1891

[38] J. P. Martinez and S. Olmos, “Detection of T wave alternans in non- Uche B. Kanu received the B.S. degree in biomed-
stationary noise: A GLRT approach,” Comput. Cardiol., vol. 30, pp. 161– ical engineering from Columbia University, New
164, Sep. 2003. York, NY, in 2005, and the M.S. an Ph.D. degrees
[39] J. P. Martinez and S. Olmos, “A robust T wave alternans detector based on in biomedical engineering from Cornell University,
the GLRT for Laplacian noise distribution,” Comput. Cardiol., vol. 29, Ithaca, NY, in 2007 and 2011, respectively.
pp. 677–680, Sep. 2002. He is currently a Research Scientist at Weill Cor-
[40] “Electrocardiogram (ECG) Signal Processing,” in Wiley Encyclopedia of nell Medical College, New York. His current research
Biomedical Engineering, vol. 2, M. Akay, Ed. New York: Wiley, Apr. interests include cardiac electrophysiology, with an
2006, pp. 1298–1313. emphasis on alternans and alternans control.
[41] V. Monasterio, P. Laguna, and J. P. Martinez, “A multilead scheme based
on periodic component analysis for T wave alternans analysis in the ECG,”
Ann. Biomed. Eng., vol. 38, no. 8, pp. 2532–2541, Aug. 2010.
[42] Z. Qu, A. Garfinkel, P. S. Chen, and J. Weiss, “Mechanisms of discordant
alternans and induction of reentry in simulated cardiac tissue,” Circula-
tion, vol. 102, no. 14, pp. 1664–1670, Oct. 2000.
[43] M. A. Watanabe, F. H. Fenton, S. J. Evans, H. M. Hastings, and A. Karma,
“Mechanisms for discordant alternans,” J. Cardiovasc. Electrophysiol., David J. Christini (S’96–M’97) received the B.S. de-
vol. 12, no. 2, pp. 196–206, Feb. 2001. gree in electrical engineering from the Pennsylvania
[44] H. Hayashi, Y. Shiferaw, D. Sato, M. Nihei, S.-F. Lin, P.-S. Chen, State University, University Park, in 1991, and the
A. Garfinkel, J. N. Weiss, and Z. Qu, “Dynamic origin of spatially discor- M.S. and Ph.D. degrees in biomedical engineering
dant alternans in cardiac tissue,” Biophys. J., vol. 92, no. 2, pp. 448–460, from Boston University, Boston, MA, in 1993 and
Jan. 2007. 1997, respectively. He did postdoctoral training in
[45] F. X. Witkowski, L. J. Leon, P. A. Penkoske, W. R. Giles, M. L. Spano, cardiac electrophysiology at Cornell University Med-
W. L. Ditto, and A. T. Winfree, “Spatiotemporal evolution of ventricular ical College, New York, NY.
fibrillation,” Nature, vol. 392, no. 6671, pp. 78–82, Mar. 1998. He is currently a Professor in the Departments
[46] A. Karma, “Electrical alternans and spiral wave breakup in cardiac tissue,” of Medicine and Physiology and Biophysics, Weill
Chaos: Interdiscipl. J. Nonlinear Sci., vol. 4, pp. 461–472, Sep. 1994. Cornell Medical College, New York, NY. He is also
with the Greenberg Division of Cardiology, Weill Cornell Medical College.
His current research interests include cellular to organ-level cardiac electro-
physiological dynamics, with an emphasis on understanding the mechanisms
underlying arrhythmia initiation and in developing new arrhythmia therapies.

Shahriar Iravanian was born in Iran in 1970. He


received the M.D. degree from the Tehran Univer-
sity of Medical Sciences, Tehran, Iran, in 1996, and
the M.S. degree in computer science from the Johns
Hopkins University, Baltimore, MD, in 2000.
He was a Postdoctoral Fellow in the Cardiac Bio-
electric System Laboratory, Johns Hopkins Univer-
sity, the Cardiac Electrodynamics Laboratory, Weill
Cornell Medical College, New York, NY, and the
Cardiac Biophysics Laboratory, Emory University,
Atlanta, GA. In 2011, he finished his fellowship in
clinical cardiac electrophysiology from Emory University, where he is currently
a practicing Cardiac Electrophysiologist. He is also with Southeast Perma-
nente Medical Group, Atlanta. His current research interests include theoretical
and experimental research in cardiac electrophysiology, especially dynamics of
reentrant arrhythmias in heart and cardiac signal processing.

Vous aimerez peut-être aussi