So in this lecture, we'll be talking about the data model used by Adewusi forecast, so the main thing
to remember is that US forecast is not an API like Cyclone or Tenzer flow.
So your data is not an umpire, Ray, and your model is not really an object with fit and predictive
functions.
Adewusi forecast requires your data to be in a specific format.
So that's what we'll be discussing in this lecture.
By the end of this lecture, you should be able to relate how eight of US forecast treats a time series
data set to the data format we've been using in this course.
To remind you, we've been looking at a time series, Arrays of Shape TBD, where T is the number of
time steps and D the dimensionality.
So the basic format will need for us forecast is a CSV, as you recall, a CSV is just a text file organized
as a table.
Each line is a row and each column is separated by columns for a simple one dimensional time series.
We need three columns.
The first column is Timestamp.
This must be in a typical daytime format with year, month, day and optionally hour, minute and second.
So, for example, if you're working with the Time series where the Time index is just an integer that
will not work, your time index has to be in the form of a daytime string.
The second column is the target value.
Basically, this represents the amplitude of your time series.
So if your Time series is the price of a stock over time, then this column would still the price.
The third column is the item ID.
Basically, this allows you to have separate time series for multiple items at once with separate forecast
for each.
So for example, if you're a company like Wal-Mart that sells many products, you can have a separate
time series for the sales of each product.
Just give them each a unique item ID for stock prices.
You could have separate stocks, for example, you could try to make a forecast for all five hundred
stocks in the S&P.
So this is like a vector auto regression, but with the much more powerful model.
Now, Amazon forecast also has a concept for a different kind of time series called a Related Time series,
as you recall.
One thing we can do in machine learning is to use other features in order to help us predict the value
of our target.
For example, the number of sales of a product might be influenced by its price, and whether it was
raining outside for us will be using the other columns of the stock price data set.
As you recall, these typically come with open, high, low, close and volume columns.
The close price is typically the column that people are most interested in.
And so that would represent our Target Time series.
That's the one we're going to try to predict.
The other columns can be used as related time series as before.
This will be stored as a CSV and the format will be very similar.
Specifically, we will again require columns for timestamp in item ID.
The other columns can be whatever we choose.
So for the coming example, that would be open, high, low in volume.
One important fact to note about Amazon forecast is that by default, it treats missing data as zero.
This is problematic because we know that stock price data is not available on non-trading days.
Therefore, the Time series will effectively fluctuate between very large values and zeroes.
Now, one solution is just to upload the data as is, and see if Amazon forecast is smart enough to
predict these variations.
Theoretically, this should be possible since Amazon forecast is advertised as a state of the art no
experience necessary solution.
Another option is to fill in the missing data ourselves.
Amazon forecast does have some options for this, but in my opinion they are not that flexible.
For example, we know that for stock prices we would like to carry the previous value forward, but
there is currently no option for this.
Therefore, what we will do is fill in missing data inside our CSV before uploading to US three.
In this way, we can have more control over how missing data is dealt with.
Another question to consider is whether or not we should pre-process our data, as you've seen, this
is quite important when it comes to Time series.
For example, we like to difference our data so that it becomes stationary.
We also like to normalize or standardize our data so that each dimension takes on values along the same
scale.
But for this exercise, we will not do any preprocessing on our data.
This will let us confirm or validate whether or not Adewusi forecast is smart enough to handle these
transformations automatically, given that it is a paid solution that takes hours of training time and
several minutes just to pre-process the data and generate forecasts, one might expect this to be the
case.
It's also advertised for those with no machine learning experience, which is another sign that these
transformations should be done automatically.
Someone without machine learning experience wouldn't know about data standardization or stationary,
so it stands to reason that this would be handled without any intervention.
I think this would be a prerequisite for any enterprise solutions such as this.
The final topic I want to discuss in this lecture is what kinds of data HWC forecast is appropriate
for for us.
We'll be using it to predict stock prices.
I've chosen this problem because we've already established that it is a hard problem.
So an obvious question to ask is, if we take a powerful enterprise solution and throw it at this problem,
will we get a better result to contrast something like airline passengers would not be interesting because
we can do that on our home computers in a few seconds.
That's also the reason why I'm conflating stock prices with stock returns.
We know that smart models like Arima will do different thing automatically and hence under the hood.
It really is working with a stationary series of returns rather than actual prices.
However, the final output is still a price because it accumulates the returns and does the reverse
transformation.
As you saw previously, one common mistake by many beginners and bloggers is that they do one step forecast
directly on the price and present them as a multistep forecast.
And what they end up really doing is just building a model that tries to predict the previous value.
In the Time series, we'll see that Amazon forecast does not allow any opportunity to make such mistakes
because the forecast is always several steps ahead from the data that you actually provide.
But aside from forecasting stock prices or stock returns, if you look at Amazon's documentation, you'll
see that it's really geared towards businesses.
We see this immediately when we consider that the time index is a time stamp and not just a generic
time index.
For example, if you are analyzing brain signals or the GPS on a car, you don't really care about the
date or the time.
And of course, those are really nonbusiness applications.
Adewusi forecast also allows you to upload item metadata such as brand color, model category and other
features of items that might be sold or used by a business or some example industries.
Amazon mentions are retail, finance, logistics and health care.
Some applications they list are inventory forecasting, workforce forecasting, web traffic forecasting,
service capacity forecasting and financial forecasting.
So clearly based on Amazon's own advertising, we can tell that this product is really meant for businesses.
So here are some specific use cases, if you're in retail, you can forecast product demand, which
would allow you to control the amount of inventory and pricing for different store locations.
If you're in supply chain planning, you can forecast the quantity of raw goods and services required
by manufacturing.
For many businesses, forecasting can be used for staffing levels, advertising, energy consumption
and server capacity.
Finally, forecasting can be used for operational planning.
For example, forecasting the amount of web traffic to your website or even your company's usage of
Adewusi itself.
OK, so hopefully this list gave you some idea of how HWC forecast could be used in your business and
the different types of time series that can be used for.