By Anand Pai V
Before choosing a forecasting algorithm, write down a prediction rule simple enough to calculate by hand. It gives the eventual model a concrete comparison and helps expose mistakes in the evaluation.
For a first baseline, predict that the next value will equal the most recent observed value. Forecasting literature calls this the naïve method. The name describes its simplicity; it does not mean that a more elaborate method will automatically outperform it. Hyndman and Athanasopoulos on simple forecasting methods
Define when the prediction is made
Imagine a fictional help desk recording ticket arrivals on consecutive days. The six counts are 40, 44, 43, 47, 46, and 50. These small, invented numbers teach the calculation; they are not results from a real support system.
Our task is precise: after each day ends and its final count is available, forecast the next day's arrivals. Begin evaluation after day 3. That leaves days 1–3 as the initial history and days 4–6 as the three forecast targets.
At the end of day 3, the latest observed count is 43, so the forecast for day 4 is 43. Only after day 4 finishes do we learn that the actual count was 47. That observed value can then support the next forecast.
Walk forward through the example
Keep one row for each prediction. Record when it was made, the forecast, the eventual observation, and the absolute error.
| Forecast made after | Target day | Forecast | Actual arrivals | Absolute error |
|---|---|---|---|---|
| Day 3 | 4 | 43 | 47 | 4 |
| Day 4 | 5 | 47 | 46 | 1 |
| Day 5 | 6 | 46 | 50 | 4 |
Each forecast uses information already available at its own prediction time. This is a simple walk-forward evaluation, also called evaluation with a rolling forecasting origin. In time-series cross-validation, each training history precedes the observations it is used to predict. Hyndman and Athanasopoulos on time-series cross-validation
Using day 4's actual count to forecast day 5 is legitimate here because our task permits a daily update. Using day 5's actual count to create day 4's forecast would not reproduce that task.
Measure error in useful units
An absolute error is the size of the gap between actual and forecast, ignoring its sign. Mean absolute error, or MAE, averages those gaps. For these three predictions, MAE is (4 + 1 + 4) divided by 3, which equals 3 tickets. MAE retains the units of the observations. Hyndman and Athanasopoulos on forecast accuracy
This means the average absolute miss across these three example forecasts was 3 tickets. It does not mean every forecast was within 3 tickets, or that tomorrow's error will be 3. Keep the individual errors beside the average so a large miss cannot disappear into a single summary.
A proposed model should face the same target days, information cutoff, and metric. A lower score on easier dates would not establish an improvement over this baseline.
Keep the forecast horizon consistent
Now change the task: after day 3, predict all of days 4, 5, and 6 at once. The naïve method gives 43 for all three days. Their absolute errors are 4, 3, and 7, giving an MAE of 14 divided by 3, approximately 4.67 tickets.
The earlier daily-updated score was 3. Comparing it directly with a model's three-day batch issued at one origin would mix different tasks. A forecast horizon tells you how far beyond the current information you must predict. Match it to the decision the forecast will support. Time-series evaluation by forecast horizon
Try the next step
Return to the daily-updated task. Day 6 ends with 50 tickets, and day 7 eventually records 48. Before reading on, calculate the day 7 forecast, its absolute error, and the MAE across days 4–7.
The forecast is 50, the absolute error is 2, and the updated MAE is (4 + 1 + 4 + 2) divided by 4, or 2.75 tickets. The lower average describes this extended example only. It does not demonstrate that the method learned a better rule.
Choose the next comparison carefully
If arrivals follow a weekly pattern, yesterday may be a weak comparison. A seasonal naïve baseline uses the last observed value from the corresponding season, such as the same weekday one week earlier. Simple seasonal forecasting
Our six-day example cannot establish that pattern. Use a longer evaluation period covering relevant cycles before choosing a model. Save the baseline's dated predictions and errors so every later method has a fair, reproducible test to beat.