R-peak Detection in Bio-signal Analysis Using FFT and Wavelet Transform.
1. R-peak Detection Overview
R-peak detection is a crucial step in the analysis of ECG (Electrocardiogram) signals, as it identifies the QRS complex, particularly the R-wave, which is the most prominent and steep part of the ECG waveform. Accurate detection is critical for analyzing heart rate variability (HRV), arrhythmias, and other cardiac parameters.
2. FFT (Fast Fourier Transform) for R-peak Detection
FFT is a mathematical technique to transform a signal from the time domain into the frequency domain. It is commonly used in signal processing to analyze the spectral components of a signal.
-
How FFT Works in R-peak Detection:
- ECG signals contain low-frequency components (P and T waves) and higher-frequency components (QRS complex).
- FFT decomposes the signal into its frequency components, highlighting the dominant frequency range.
- Filtering is applied in the frequency domain to remove noise and irrelevant frequency components while retaining the QRS-specific high-frequency range.
- After filtering, the inverse FFT transforms the signal back to the time domain, where prominent peaks (R-peaks) are detected.
-
Advantages:
- Effective at filtering noise, such as baseline wander and powerline interference.
- Simple implementation with fast computation for real-time applications.
-
Challenges:
- Sensitive to motion artifacts and other non-stationary noise.
- Limited in detecting peaks with highly variable morphology.
3. Wavelet Transform for R-peak Detection
Wavelet Transform (WT) provides a time-frequency representation of a signal, making it highly effective for analyzing non-stationary and multi-scale signals like ECG.
-
How WT Works in R-peak Detection:
- WT decomposes the ECG signal into a series of wavelet coefficients across different scales and resolutions.
- Specific wavelet functions (e.g., Haar, Daubechies, or Symlets) are chosen to match the shape of the QRS complex.
- High-frequency wavelet coefficients emphasize sharp transitions like R-peaks, while low-frequency coefficients capture broader components like P and T waves.
- A reconstruction process can isolate the QRS complex, and thresholding is applied to detect R-peaks.
-
Advantages:
- Robust against noise and baseline wander due to multi-resolution analysis.
- Can adapt to variable signal morphologies by selecting an appropriate wavelet function.
- Works well with non-stationary signals, making it suitable for ECG with dynamic variations.
-
Challenges:
- Computationally more intensive compared to FFT.
- Requires careful selection of wavelet types and scales for optimal results.
4. Comparison of FFT and Wavelet Transform for R-peak Detection
| Feature | FFT | Wavelet Transform |
|---|---|---|
| Signal Domain | Frequency domain | Time-frequency domain |
| Noise Robustness | Moderate | High |
| Handling Non-Stationarity | Limited | Excellent |
| Computation Speed | Fast | Moderate to high |
| Customization | Minimal | High (wavelet selection) |
5. Practical Applications
- FFT: Used for simple, low-complexity ECG signal processing where real-time speed is critical. Often combined with other methods for improved accuracy.
- Wavelet Transform: Preferred for detailed ECG analysis in clinical diagnostics, wearable ECG devices, and research applications requiring high accuracy and adaptability.
Both methods have their strengths and are often used in hybrid approaches for robust R-peak detection in noisy or complex ECG signals.
Why is it important to detect the R-peak in the ECG signal?
In the ECG signal, the R-peak is the most pronounced waveform indicating the depolarization of the ventricle.
The R-peak is used as a reference point for calculating various cardiac related indicators such as heart rate (HR), heart rate variability (HRV), and QT interval.
Accurate R-peak detection is very important because these indicators provide important information in various medical and healthcare fields such as heart disease diagnosis, stress monitoring, and exercise effectiveness analysis.
How to detect R-peak using FFT, and what are the limitations?
FFT is used to analyze the frequency components of a signal by converting a time-domain signal into a frequency-domain.
The direct use of FFT for R-peak detection is not common.
FFT shows the overall frequency characteristics of a signal, but it is difficult to accurately capture abrupt changes that occur over a short period of time, such as the R-peak.
Furthermore, since FFT is based on the assumption that the signal is normal and periodic, it can be less accurate in noisy or abnormal ECG signals.
How to detect R-peak using wavelet transform, and what are the advantages over FFT?
Wavelet transform is an effective method for time-frequency analysis, providing information in the time and frequency domains simultaneously.
Discrete wavelet transforms (DWT) are mainly used for R-peak detection. DWT decomposes signals into multiple frequency bands, where selecting appropriate wavelet functions (e.g., Daubechies, Symlet) and decomposition levels can effectively separate the characteristic frequency components corresponding to the R-peak.
The advantages of wavelet conversion include.
- Time resolution: Unlike FFT, time information is maintained, so that the location of the R-peak can be accurately found even in abnormal or noisy signals.
- Multiple resolution analysis: The signal can be analyzed in a wide range of frequency bands, allowing the capture of various features of the R-peak.
- Noise cancellation effect: You can reduce the effect of noise by removing signals in certain frequency bands.
What is the specific procedure for R-peak detection using wavelet transform?
The general procedure is as follows.
- Pre-processing: Improve signal quality through pre-processing processes such as removing baseline fluctuations and removing noise.
- Wavelet Transformation: Perform DWT by selecting the appropriate wavelet function and resolution level.
- Feature Extraction: Extracts characteristic wavelet coefficients (mainly detailed coefficients) corresponding to the R-peak.
- R-peak detection: detects the R-peak using the maximum or specific threshold of the extracted coefficient.
- Post-processing: Verifies the accuracy of detected R-peaks and removes false-detected peaks.
What are the indicators for evaluating R-peak detection performance?
R-peak detection performance is assessed using the following indicators.
- Accuracy: Indicates the rate of agreement between the actual R-peak and the detected R-peak.
- Sensitivity: Indicates how accurately the actual R-peak has been detected.
- Specificity: Indicates how accurately the non-R-peak part is distinguished.
- Positive Predictive Value (PPV): Indicates the percentage of the actual R-peak among the detected peaks.
![WEARABLE_INSIGHT [FORUM]](https://wearableinsight.net/wp-content/uploads/2025/04/로고-3WEARABLE-INSIGHT1344x256.png)

