Time series forecasting
Goal: understand and apply the concepts in the modules through the proposed exercises. Mark each module after studying it. Use the assessment to check your understanding. You may start this course directly without mandatory prerequisites.
Learning plan
- Temporal structure and preparation
- Baselines and smoothing
- Rolling-origin validation
- Errors and intervals
- Drift and operational use
- Case design and comparison validity
- Marginal efficiency and constraints
- Sensitivity and conditional recommendation
Recommended knowledge (not mandatory): Data literacy and metrics, Management dashboards.
1. Temporal structure and preparation
A time series has order and dependence among observations. Inspect frequency, missing values, unit changes, trend and seasonality. Do not replace missing values with zero without understanding their meaning. Distinguish unusual observations from confirmed errors. Record events changing the process and preserve chronological order during preparation.
Prepare twelve fictional monthly observations with a missing value and a unit change.
2. Baselines and smoothing
Start with a naive forecast using the latest observation or a seasonal naive forecast reusing the equivalent seasonal period. Exponential smoothing gives greater weight to recent observations via a parameter alpha between zero and one: the new forecast is alpha times the observation plus (1 minus alpha) times the previous forecast. More complex models should demonstrate out-of-sample benefit; fitting historical data well is insufficient.
Calculate smoothing with alpha 0.3, prior forecast 100 and observation 120.
3. Rolling-origin validation
Evaluate forecasting using successive training origins and future test periods. Random splitting may transfer future information into the past. Calculate errors by horizon and keep preparation inside each training window. Reserve a final period to confirm the chosen model without selecting parameters again on that period.
Design three chronological training and test windows for 24 fictional months.
4. Errors and intervals
Compare mean absolute error and root mean squared error, which penalises larger errors more. Absolute percentage error is problematic when actual values are zero or near zero. Evaluate bias and empirical coverage of prediction intervals. An interval represents future uncertainty under assumptions, not a guarantee that every value will lie within it.
Compare errors of 2, 2 and 8 against 4, 4 and 4 using MAE and RMSE.
5. Drift and operational use
Monitor post-deployment performance by horizon and demand regime. A structural shift may make old parameters unrepresentative. Define update frequency, baseline model, error alert and human intervention rules. Link forecasts to concrete decisions accounting for asymmetric overage and shortage costs; a point forecast alone does not determine inventory levels.
Propose a review rule when error increases over three consecutive periods.
6. Case design and comparison validity
Entirely fictional scenario: Two demand forecasts for a fictional service. Each alternative, A and B, is evaluated on 100 units. A valid outcome means forecasts within the tolerance set before analysis. A produces 45 valid outcomes with 135 minutes of total effort; B produces 65 with 235 minutes. These figures are training data, not observed market outcomes. The rate divides valid outcomes by evaluated units; absolute rate differences are expressed in percentage points. For example, going from 20% to 30% represents ten percentage points, not a ten percent relative increase. To compare average effort, divide minutes by valid outcomes. Define identical counting rules for both alternatives and record data provenance. The analysis unit must be defined before the test. Comparability requires checking composition, measurement conditions, missingness and possible dependencies. For this domain, it is particularly important to separate training and test chronologically and compare against a baseline model. Specify which variables should be stratified and how outcomes are reconciled with the reference source. If assignment is not random, treat the difference as descriptive until adequate causal evidence exists.
Exercise: write a protocol specifying population, unit, success definition, exclusions, reference source and comparison method; identify two case-specific threats to validity.
7. Marginal efficiency and constraints
The marginal effort cost of moving from A to B is the difference in minutes divided by the difference in valid outcomes, not B’s average effort. Assume a ceiling of 185 minutes and a minimum target of 46 valid outcomes. Compare both constraints simultaneously. If neither option meets both, redesign the approach or seek a decision on which constraint may change. Descriptive improvement does not prove causation or guarantee repetition. Before deciding, separate training and test chronologically and compare against a baseline model. Record observations, assumptions and missing information. Distinguish a hard constraint from a negotiable preference. B uses 100 additional minutes and A leaves 50 minutes of capacity under the ceiling. If there is additional benefit per outcome, compare it against the opportunity cost of additional minutes; without appropriate valuation financial return cannot be inferred. The decision must also consider quality, distribution of effects and dependencies.
Exercise: calculate average effort, marginal effort and shortfall against each constraint. Propose a third alternative preserving quality, identifying which assumption requires testing.
8. Sensitivity and conditional recommendation
Test the robustness of the comparison of two demand forecasts for a fictional service. Suppose a quality review reduces B’s valid outcomes by 22, with effort unchanged. Calculate the new rate and difference relative to A. The tie threshold is the loss of 20 valid outcomes; larger losses reverse the ranking. This scenario is not a probability forecast: it is an explicit perturbation of an assumption. Also test scenarios involving increased effort, measurement failures and capacity constraints. Validation must include the need to separate training and test chronologically and compare against a baseline model. Produce a recommendation with a stop condition, guardrail indicator, required data and review date, avoiding extrapolation from 100 units to the whole population without justification.
Exercise: build a three-scenario matrix covering the stated loss, increased effort and their combination. Identify the reversal threshold, data to collect and rollback condition.
Final assessment
Answer all ten questions, with three options and one correct answer. To obtain the participation certificate, mark every module and achieve at least 80% (eight correct answers). You can repeat the assessment without limit. No passing grade is required between modules.
Participation certificate
Participation document issued by the independent Academia Digital 360 project. It is not an official, accredited or professional certification and does not confer any academic degree or recognised qualification. Identity and participation are not independently verified.