Short-Time Fourier Transform (STFT) for PPG

The Short-Time Fourier Transform (STFT) computes the frequency spectrum of successive windowed PPG segments, creating a time-frequency spectrogram that visualizes how the cardiac frequency, motion artifacts, and respiratory modulation evolve over time.

STFT applies a sliding window function w(t-τ) to the PPG signal and computes the FFT at each window position: S(τ,f) = ∫ x(t)·w(t-τ)·exp(-j2πft)dt. The resulting spectrogram S(τ,f) displays spectral energy as a function of both time and frequency. Window length determines the time-frequency resolution tradeoff: longer windows (8–10 s) provide better frequency resolution for separating cardiac and motion peaks, while shorter windows (2–4 s) provide better temporal resolution for tracking rapid HR changes.

PPG spectrograms clearly visualize the cardiac fundamental frequency track (typically 0.8–3 Hz), its harmonics (1.6–6 Hz), motion artifact tracks (variable), and respiratory modulation (0.1–0.5 Hz). Automated spectral peak tracking on the spectrogram using dynamic programming or Viterbi algorithms extracts continuous heart rate estimates while rejecting motion artifact peaks based on harmonic structure and continuity constraints.

Multi-taper spectral estimation (Thomson's method) replaces the single window with multiple orthogonal windows (Slepian sequences), providing lower variance spectral estimates with broader bandwidth. For PPG, 3–5 tapers with time-bandwidth product NW = 3–5 reduce spectral variance by 60–80% compared to single-window STFT, improving motion artifact peak separation from cardiac peaks.

Frequently Asked Questions

What window function is best for PPG STFT?

Hanning and Hamming windows are standard choices providing good sidelobe suppression (-31 to -43 dB). Kaiser windows with β=6–10 offer adjustable sidelobe control. Gaussian windows are used when the Wigner-Ville distribution interpretation is desired.

How does STFT compare to wavelet analysis for PPG?

STFT provides uniform time-frequency resolution across all frequencies. Wavelets provide higher frequency resolution at low frequencies and higher time resolution at high frequencies. For PPG where cardiac and motion peaks occupy a narrow band, STFT is often sufficient.

Can STFT separate overlapping cardiac and motion frequencies?

When cardiac and motion frequencies are within one frequency resolution bin (Δf = 1/window_length), STFT cannot separate them. Longer windows or super-resolution methods (MUSIC, ESPRIT) are needed for closely spaced frequencies.

Related Algorithms