# The Effects of Compression on the Detection of Atrial Fibrillation in ECG Signals
## 3 Results  
R-R interval entropy is employed as an indicator of AF. Performance is evaluated by generating the ROC, and hence estimating the AUC, using a range of entropy thresholds in the AF detection algorithm. By way of example, Table 1 presents the performance of the compression algorithm for different CRs, in terms of both waveform fidelity as expressed in PRD, as well as in \"functional\" performance in AF detection, presented as PRD, AUC, and specificity, where the threshold has been varied to achieve a fixed sensitivity equal to 0.950. As expected, in this example, as CR increases, signal distortion expressed as PRD increases, while AF detection expressed as specificity drops. Figure 3 shows an example of an original ECG waveform from the AF database, along with two compressed versions of the same signal. The loss of detail in the reconstructed signals as CR increases can be seen in this figure. However, as noted in the Introduction,  
\begin{table}
\begin{tabular}{c c c c} \hline \hline
**CR** & **PRD (\%)** & **AUC** & **Specificity** \\ \hline
0 & 0 & 0.947 & 0.717 \\
0.953 & 0.006 & 0.946 & 0.714 \\
5.002 & 5.236 & 0.948 & 0.728 \\
10.004 & 9.194 & 0.951 & 0.751 \\
14.010 & 12.437 & 0.950 & 0.739 \\
20.007 & 17.765 & 0.951 & 0.746 \\
25.031 & 22.239 & 0.952 & 0.764 \\
30 in the context of a computer-aided diagnostic application the goal is not necessarily to preserve the signal fidelity, rather the goal is to preserve diagnostic information, therefore, significant distortion of the signal, as illustrated for the higher CR values in Figure 3, may still be tolerated, while at the same time, good AF detection performance can still be maintained. Figure 4 illustrates three AF detection ROC curves averaged over all patient records, at three different CRs. ROC curves are plots of true positive rate (sensitivity) as a function of false positive rate (equal to 1--specificity). The blue line illustrates AF detection accuracy for uncompressed data. The red line represents the point where AUC starts to drop below 0.9, i.e., where performance is still reasonably high. This corresponds to a CR of 90. Finally, the yellow line shows performance for a higher CR, where performance is substantially lower (AUC = 0.75). Figure 5 plots the variation of AF detection performance as a function of CR. It is clear that the proposed AF detection approach can provide a significant reduction in data while maintaining high AF detection performance. As noted in Figure 4, detection performance reflected in AUC is preserved at a relatively high level (>0.9) up to a very high CR of approximately 90, which suggests that substantial compression of the signal is possible while maintaining reasonably good atrial fibrillation performance. For CRs greater than 90, the performance starts to reduce more rapidly. Figure 6 illustrates the variation of AF detection performance against the level of signal distortion, expressed as PRD. The AUC starts to drop below 0.9 for a PRD value of 58%. Figures 5 and 6 together highlight the point that, in terms of detection performance using the entropy-based algorithm in this paper, significant compression and substantial distortion of the signal (reflected in a high PRD value) is possible, while still maintaining good AF detection performance. RR interval irregularity, as well as being one of the most distinctive features of AF, is the most accessible ECG characteristic for AF detection. During AF, if the atrial rate becomes relatively slow and regular, the ventricular rate tends to rise, and this is manifested as reduced variability of the RR intervals. This is reflected in lower entropy [39]. From a physiology point of view, information on the regularity of RR intervals can be very useful to understand AF  
Figure 3: Original ECG signal from first 8 s of record 04126. **Top** plot: uncompressed signal. **Middle**: reconstructed signal with CR = 70.