Time Series ML Forecasting#
Description:
Machine Learning Time Series model to predict future values. This can be based on daily, monthly, or hourly values.
Function:
TS_Forecast(table = string, date_col = string, value_col = string, num_per = integer, freq = string, new_table_name = string)
Parameters:
Table: Table name on which to perform the function
Date Column: Date column to use for forecast
Value Column: Value Column to base forecast on
Number of Periods: Number of Periods to Forecast
Forecast Frequency: What is the time interval to be forecasted (hourly, daily, monthly)
New Table Name: Name for the new table
Example:
TS_Forecast(table = Budget, date_col = "Date", value_col = "Revenue", num_per = 5, freq = "Daily", new_table_name = "TS Forecasting")
Date |
Value |
|---|---|
… |
… |
6/26/2024 |
1178 |
6/27/2024 |
1085 |
6/28/2024 |
935 |
6/29/2024 |
1342 |
6/30/2024 |
1087 |
Date |
FORECAST |
Predicted Value 1 |
Predicted Value 2 |
Predicted Value 3 |
|---|---|---|---|---|
… |
… |
… |
… |
… |
2024-06-29T00:00:00.000000 |
1001.975 |
751.9004 |
1256.553 |
1001.975 |
2024-06-30T00:00:00.000000 |
1004.383 |
761.6355 |
1233.621 |
1004.383 |
2024-07-01T00:00:00.000000 |
1001.932 |
761.8277 |
1266.305 |
1001.932 |
2024-07-02T00:00:00.000000 |
1004.306 |
768.8828 |
1272.184 |
1004.306 |
2024-07-03T00:00:00.000000 |
1000.19 |
754.8353 |
1259.737 |
1000.19 |
2024-07-04T00:00:00.000000 |
1131.743 |
898.6075 |
1379.402 |
1131.743 |
2024-07-05T00:00:00.000000 |
1004.984 |
772.052 |
1255.279 |
1004.984 |