Transitioning from Univariate to Multivariate Time Series Forecasting: Predicting Store Sales for 500 Items

In this remarkable course, we’ve acquired the skillset to employ machine learning techniques for the purpose of predicting a single variable’s behavior over time, which is typically referred to as univariate time series analysis. Throughout the course, we’ve honed these techniques by applying them to predict Sunspots.

Now, I find myself contemplating how we can leverage these newfound skills, including working with windowed datasets, to transition into the realm of multivariate time series forecasting. Specifically, I’m eager to explore how we can harness these techniques to predict the sales of 500 different items in a store. This presents a thrilling challenge, and I’m keen to hear your insights and suggestions on how we can adapt our knowledge to this more complex scenario.

1 Like

Hi @Ahmed_El-Ashry

Thank your for your questions, super interesting see that you want to keep exploring the time series world.

This is a technically profound roadmap for transitioning to multivariate time series forecasting:

1. Data Handling for Multivariate Forecasting:

  • Unlike univariate series where we focused on sunspots, a multivariate series, as you aptly noted, we can deal with sales data from 500 items, observed concurrently. As we learned about data preparation, similar preprocessing steps – normalization, outlier handling, and filling missing values – remain paramount.

2. Expanding the Windowed Dataset Approach:

  • The windowed dataset technique you’ve mastered is even more crucial here. Instead of framing the problem with a single series, you’d now create windows that encompass data from all 500 items, potentially allowing the network to recognize interdependencies between different items’ sales.

3. Adapting Model Architectures:

  • While the course extensively covered RNNs and ConvNets for univariate series, multivariate forecasting often benefits from models like LSTMs due to their ability to remember long-term dependencies. Each time step in your input data will encapsulate features from all 500 items, enabling the LSTM to discern patterns spanning multiple items.

4. External Features and Embeddings:

  • Consider external factors that could impact sales, such as holidays or promotions. Embeddings, similar to what’s used in NLP (which shares parallels with sequence data), can be incorporated for categorical features like item IDs.

5. Model Evaluation:

  • Given the complexity, it’s vital to have a robust validation strategy. Techniques like TimeSeriesSplit or rolling forecasts can be advantageous. Remember, overfitting is a concern, especially with more data features, so regularize and monitor model generalization closely.

6. Beyond RNNs and LSTMs:

  • Advanced architectures such as attention mechanisms and Transformer-based models have shown promise in multivariate forecasting. They can weigh the significance of different items and time steps, potentially leading to more accurate predictions.

Recommended Resources:
There is a really good book “Deep Learning for Time Series Forecasting” by Jason Brownlee offers insights into both univariate and multivariate forecasting using deep learning. You can read more about that.

And i can provided additional documentation or suggestion if it’s need it.

Please let me know if helps :hugs:

3 Likes