Multivariate Time Series Analysis with LSTMs - out-of-sample forecast??

Hello all,

In this article the author states that you can use recursive loops if you would like to predict the demand not only for the next hour but longer. Both workflows the authors recommends as starting points show a univariate time series prediction.

Is this even possible for a multivariate time series analysis?

If I have a single time series (e.g. historical sales data per day or month) I could predict the value for the next time step, then take this predicted value as another input value and repeat the forecast with a recursive loop (iterative approach, out-of-sample forecast).

But how can I do this with multiple different input variables? How can I take the predicted value of the next time step as another input variable and repeat the forecast so that I get more than one future time steps?

Thanks for your support!

1 Like

Hello @nicolai,

you are absolutely right! In case of a multivariate time series analysis it is not as easy as I thought. You would need in addition to the predicted value also the values for the additional features at the next time step(s).

How I would handle the situation depends a bit on the additional features.

  • For some features we know the value for the next time steps already, e.g. whether or not it is a vacation day.

  • For other features we might want to use another resource, e.g. for the temperature we could use the forecasted temperature.

  • And for other features it might make sense to train the network to predict them as well and add them as additional outputs to the network.

Thank you for bringing this up. I will now fix the blog post :slight_smile:


This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.