## 5 Dynamic Time Warping (DTW) Libraries in Python With Examples

The world of time series analysis can be complex, and finding the right Python library for Dynamic Time Warping can be even more so. That’s where this tutorial comes in! My goal is to provide you with an easy-to-follow guide that will help you understand the various options available and make the right choice for your project. Whether you are a beginner or an expert, you will find valuable insights here....

April 13, 2023 · 6 min · Mario Filho

## 8 Ways To Calculate Correlation Between Two Time Series In Python

Analyzing correlations is a critical step in understanding complex data relationships. It’s a fast way to find how similar two time series are. Python offers a wide range of libraries that make calculating correlations between two time series a breeze. In this tutorial, we’ll explore some of the most popular libraries for correlation analysis, including NumPy, Pandas, Scipy, Polars, CuPy, CuDF, PyTorch, and Dask. Let’s get started! Correlation Between Two Time Series Using NumPy NumPy is the most popular Python library for numerical computing....

March 15, 2023 · 5 min · Mario Filho

## Deseasonalizing Time Series Data With Python

Time series data can be a valuable tool for predicting trends and making informed business decisions. However, it can be difficult to analyze due to seasonal patterns and other fluctuations that can obscure underlying trends. That’s where deseasonalizing comes in, allowing you to isolate trends and make more accurate predictions. In this tutorial, we’ll explore two different approaches to deseasonalize time series data in Python: additive models and multiplicative models....

March 10, 2023 · 8 min · Mario Filho

## Detrending Time Series Data With Python

In this tutorial, we will explore various detrending models using two popular Python libraries - statsmodels and scipy. While there are several detrending methods, we will focus on four models: We will start with a constant model from the scipy library, which assumes that the trend of the time series is a straight horizontal line. Then we move to a model that captures a linear trend in the data. After that, we will explore a quadratic model, using the statsmodels library....

March 10, 2023 · 6 min · Mario Filho

## How To Measure Time Series Similarity in Python

In this tutorial, we’ll explore some practical techniques to measure the similarity between time series data in Python using the most popular distance measures. To make sure that the results are not affected by noise or irrelevant factors, we’ll apply techniques such as scaling, detrending, and smoothing. Once the data is preprocessed, we can use simple distance measures like Pearson correlation and Euclidean distance to measure the similarity of two aligned time series....

March 8, 2023 · 8 min · Mario Filho

## Differencing Time Series In Python With Pandas, Numpy, and Polars

When working with time series data, differencing is a common technique used to make the data stationary. Stationary data is important because it allows us to apply statistical models that assume constant parameters (like the mean and standard deviation) over time, and this can improve the accuracy of our predictions. Let’s see how we can easily perform differencing in Python using Pandas, Numpy, and Polars. First-order Differencing First-order differencing involves subtracting each value in the time series from its previous value....

March 4, 2023 · 8 min · Mario Filho