Skip to content

Mission 8 - Train Time Series

Estimated time for completing this mission: 20 mins

Learning Objective

Train your first time series model with different feature variables.

Scenario

Imagine you are tasked to predict the future sales of a certain company and you are given the last two years of sales to work with. Using time series prediction and the dataset of the history of sales, you are able to train a model which can later be used on new unseen data to predict future sales (see the next mission for prediction with time series). First thing you have to do is perform training on the dataset.

Know-How Refresh

Time series prediction is a very powerful tool for predicting future values. Here, besides feature variables and a target variable, you have a time series variable as well. Time series in other words is a repeated measurement over time.

BLOX used in this mission:

  • Basics/Start
  • MyData/FinalData
  • Database/Group By
  • AI/Train Advanced Forecaster
  • Basic/Display

startBlox

BLOX used for this mission

Data

The same data set will be used as for the previous task FinalData.

Steps

Please refer to the Navigation Guide to perform the steps below

  1. In the Module 3 folder press the green plus button to create new logic named Train Time Series
  2. Drag and drop logics that will be used for this mission including the data set FinalData
  3. Next, connect the "Starting" BLOX to the "MyData" BLOX
  4. Then, connect the output of the "MyData" BLOX to a "Group By" BLOX and specify "ORDERDATE" and "sum" as the two parameters
  5. Now, connect the output from the "Group By" BLOX to "Train Series Model", and specify the "Time Variable" ("ORDERDATE"), "Target Variable" ("SALES"), "Time Format" ("%Y/%m/%d"), "Look-back Window Size" (15 preferably), "Training Intensity" ("Medium"), and "Model Name" ("Time Series Model")
  6. Then the result should be displayed on a "Display" BLOX, hence connect the "Compare Graph" output to the "Display" BLOX
  7. Press Start button to execute the logic
  8. After all the logics have been executed, double click on the model to see training results

Results and Summary

startBlox

Final logic composition

startBlox

Predicted vs True values

Well done! Now let's move on to the next mission!