Published on

Accelerating Time Series Analysis - Use Cases, Types, Methods, and Top Python Libraries

Authors
  • avatar
    Name
    Nathan Peper
    Twitter

Time-series data is a sequence of data points collected over successive time intervals, allowing us to track changes over milliseconds, days, or even years. Time-series data is commonly used in various fields such as economics, finance, healthcare, engineering, and more. The use cases are numerous, but it's generally used to analyze patterns, trends, and behaviors that evolve over time.

Example Use Cases

  • Financial trading systems: stock prices, classic securities, newer cryptocurrencies.
  • Weather patterns: temperature, dew point, humidity, pressure, etc readings at the local, regional, or global level to monitor or predict future weather trends and events.
  • Economic Indicators: monthly unemployment rates, consumer price index (CPI), job listings, etc.
  • Healthcare patient monitoring: biosensor data for in-hospital patient monitoring and/or remote patient monitoring of heart rate, blood pressure, oxygen saturation, respiratory rate, physical activity, blood sugar levels, etc.
  • Physical system monitoring: sensor data from equipment, machinery, and connected devices (IoT) for use cases such as status tracking, utilization forecasting, energy consumption, and preventative maintenance.
  • Software system monitoring: virtual machines, containers, services, applications, and web pages to monitor traffic, utilization, status, logs, etc.
  • Asset tracking applications: vehicles, trucks, physical containers, and pallets, for dynamic routing, arrival time prediction, and supply chain optimization.
  • Business intelligence tools: tracking key metrics and the overall health of the business

Types of Time Series Analyses

  • Univariate Time Series: only one variable varies over time.
  • Multivariate Time Series: more than one variable varies over time. Each variable not only depends on its past values but also could depend on the other variables.

Methods of Time Series Forecasting

  1. Autoregression (AR): Univariate
  2. Moving Average (MA): Univariate
  3. Autoregressive Moving Average (ARMA): Univariate
  4. Autoregressive Integrated Moving Average (ARIMA): Univariate
  5. Seasonal Autoregressive Integrated Moving-Average (SARIMA): Univariate
  6. Seasonal Autoregressive Integrated Moving-Average with Exogenous Regressors (SARIMAX): Univariate
  7. Simple Exponential Smoothing (SES): Univariate
  8. Holt Winter's Exponential Smoothing (HWES): Univariate
  9. Vector Autoregression (VAR): Multivariate
  10. Vector Autoregression Moving-Average (VARMA): Multivariate
  11. Vector Autoregression Moving-Average with Exogenous Regressors (VARMAX): Multivariate

Below is a list of popular and trending Python packages to help you speed up your time series analysis. There is a lot of overlap between these packages and obviously, we need to understand the capabilities and limitations of both the packages chosen to utilize and the use case for the analysis for a good fit. There are many articles online about the potential controversy with the forecasts from packages such as Facebook's Prophet, but if the only tool you have is a hammer, you tend to see every problem as a nail...

Prophet by Facebook

Loading...

Click to see GitHub star history
Star History Chart

statsmodels

Loading...

Click to see GitHub star history
Star History Chart

tsfresh by Blue Yonder

Loading...

Click to see GitHub star history
Star History Chart

PyCaret Time Series

Loading...

Click to see GitHub star history
Star History Chart

Sktime

Loading...

Click to see GitHub star history
Star History Chart

Darts by Unit8

Loading...

Click to see GitHub star history
Star History Chart

Kats by Facebook Research

Loading...

Click to see GitHub star history
Star History Chart

tsai by timeseriesAI

Loading...

Click to see GitHub star history
Star History Chart

GluonTS by AWS Labs

Loading...

Click to see GitHub star history
Star History Chart

PyTorch Forecasting by Jan Beitner

Loading...

Click to see GitHub star history
Star History Chart

Merlion by Salesforce

Loading...

Click to see GitHub star history
Star History Chart

Statistical Forecast by Nixtla

Loading...

Click to see GitHub star history
Star History Chart

STUMPY by TD Ameritrade

Loading...

Click to see GitHub star history
Star History Chart

tslearn

Loading...

Click to see GitHub star history
Star History Chart

lifelines by Cameron Davidson-Pilon

Loading...

Click to see GitHub star history
Star History Chart

PyFlux by Ross Taylor

Loading...

Click to see GitHub star history
Star History Chart

Alibi Detect by Seldon

Loading...

Click to see GitHub star history
Star History Chart

Greykite by LinkedIn

Loading...

Click to see GitHub star history
Star History Chart

Neural Forecast by Nixtla

Loading...

Click to see GitHub star history
Star History Chart

Orbit by Uber

Loading...

Click to see GitHub star history
Star History Chart

AutoTS by Colin Catlin

Loading...

Click to see GitHub star history
Star History Chart

If you're still interested in finding more resources for your time series analysis use cases, you can head over to GitHub and check out the "awesome-time-series" repo started by Lukasz Mentel. It has more Python packages that might help accelerate your experimentation and development, as well as additional languages and resources to help.  

Thanks for taking the time to read this overview, I hope it helps you learn something new about time series analyses and the packages and community available to help you tackle any use case.

As always, feel free to reach out to just connect or let me know if I missed any great packages or insights that should be shared!