Chapter 6. Signal Processing and Timeseries

In this chapter, we will cover the following recipes:

  • Spectral analysis with periodograms
  • Estimating power spectral density with the Welch method
  • Analyzing peaks
  • Measuring phase synchronization
  • Exponential smoothing
  • Evaluating smoothing
  • Using the Lomb-Scargle periodogram
  • Analyzing the frequency spectrum of audio
  • Analyzing signals with the discrete cosine transform
  • Block bootstrapping time series data
  • Moving block bootstrapping time series data
  • Applying the discrete wavelet transform

Introduction

Time is an important dimension in science and daily life. Time series data is abundant and requires special techniques. Usually, we are interested in trends and seasonality or periodicity. In mathematical terms, this means that we try to represent the data by (usually linear) polynomial or trigonometric functions, or a combination of both.

When we investigate seasonality, we generally distinguish between time domain and frequency domain analysis. In the time domain, we can use a dozen pandas functions for rolling windows. We can also smooth data to remove noise while hopefully keeping enough of the signal. Smoothing is in many respects similar to fitting, which is convenient because we can reuse some of the regression tools we know.

To get in the frequency domain, we apply transforms such as the fast Fourier Transform and discrete cosine transform. We can then further analyze signals with periodograms.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset