Multi-step forecasting with scikit-learn
In the previous recipe, One-step forecasting with scikit-learn, you implemented a one-step forecast. In this approach, a sequence of values from the past 10 periods ( where is used to predict the next period, referred to as . This is known as one-step forecasting, as shown in Figure 12.2.For example, in the case of monthly energy consumption data, to forecast for December 2021, you would provide data for the past 10 months (February to November 2021). This approach works well for monthly or quarterly data, but what about more granular data, such as daily or hourly? In the case of daily temperature data, this setup requires you to provide temperature values for the past 10 days to obtain a one-day forecast. This may not be an efficient approach because you would have to wait for the next day to observe a new value to generate another one-day forecast.But what if you need to predict more than one future step? For example, what if you want to forecast...