Predictive Analytics and Time Series Forecasting

Chapter 2
Business Problem Framing and Analytical Design

Diploma in Business Analytics
Predictive Analytics and Time Series Forecasting   •   Diploma

Business Problem Framing and Analytical Design

Introduction

Predictive analytics projects rarely fail because an algorithm cannot be trained. They more often fail because the analytical team solves the wrong problem, predicts an unusable outcome, uses an inappropriate time horizon, or evaluates performance with a metric that does not reflect managerial priorities. Business problem framing is therefore the foundation of predictive analytics and time series forecasting.

Problem framing translates a managerial concern—such as declining sales, excess inventory, customer churn, or staff shortages—into a precise analytical design. This design specifies what must be predicted, for whom or for what entity, by when, using which information, and according to which measure of success. It also identifies constraints, decision consequences, stakeholders, and ethical responsibilities.

A well-framed problem creates a traceable connection:

Business objective → decision → analytical question → target variable → data design → model → evaluation → action

If any link is weak, technical sophistication cannot guarantee business value.

Learning Objectives

By the end of this chapter, you should be able to:

  1. Distinguish a business problem from an analytical problem.
  2. Translate managerial objectives into target variables and analytical questions.
  3. Select an appropriate unit of analysis and forecasting horizon.
  4. Separate prediction from causal explanation and decision optimization.
  5. Choose success metrics that reflect business costs and benefits.
  6. Recognize data, operational, legal, ethical, and stakeholder constraints.
  7. Design a practical predictive analytics project from problem definition to deployment.

1. From Managerial Concern to Analytical Problem

A managerial concern is usually expressed in broad language. For example:

  • “We need to reduce stock-outs.”
  • “Which customers are likely to leave?”
  • “How many employees will we need next month?”
  • “Sales are unstable; can we forecast demand?”

These statements identify a business need but do not yet define a model. An analytical problem must specify the decision context and the information required to support that decision.

A useful framing statement has the following structure:

Given information available at time t, predict or estimate Y for unit U over horizon H, so that stakeholder S can make decision D, subject to constraints C, and success will be assessed using metric M.

For example:

Using information available at the end of each day, forecast next-day demand for each store–product combination so that replenishment staff can set order quantities, subject to supplier lead times and storage capacity, evaluated using weighted absolute error and stock-out cost.

This statement is more useful than “build a demand forecasting model” because it defines the target, unit, horizon, decision, constraints, and evaluation logic.

Business problem versus analytical problem

AspectBusiness problemAnalytical problem
FocusDesired organizational outcomeInformation needed to support a decision
ExampleReduce avoidable stock-outsForecast next-week demand by store and product
SuccessFinancial, operational, or customer resultPredictive accuracy, calibration, and decision value
OwnerManager or process ownerAnalyst, data scientist, and domain experts
Time frameUsually linked to a business cycleExplicit observation and forecast horizons

A business problem may lead to several analytical problems. Reducing stock-outs may require demand forecasting, supplier-delay prediction, inventory optimization, and exception prioritization. Analysts should not assume that one model solves the entire business problem.

2. The Analytical Design Questions

A sound design answers seven connected questions.

2.1 What decision will the analysis support?

Prediction is valuable only when it changes an action. Common decisions include:

  • how much inventory to order;
  • which customers should receive retention offers;
  • how many staff should be scheduled;
  • whether a loan application requires further review;
  • which machine should receive preventive maintenance;
  • whether a promotion should be launched.

The decision determines the required timing, precision, and tolerance for error. A forecast delivered after an ordering deadline has little operational value, even if it is statistically accurate.

2.2 What is the target variable?

The target variable, also called the response, outcome, or dependent variable, is the quantity the model is intended to predict or estimate.

Examples include:

  • units sold next week;
  • revenue in the next month;
  • probability that a customer churns within 60 days;
  • number of service calls tomorrow;
  • time until a machine failure;
  • whether an invoice will be paid late.

Target definition requires precision. “Churn” might mean cancellation, no purchase for 90 days, or account closure. “Sales” might mean orders placed, items shipped, or revenue recognized. These alternatives are not interchangeable.

A target should have:

  1. a clear operational definition;
  2. a measurement unit;
  3. a reference time;
  4. an observation window;
  5. a rule for missing, cancelled, or revised records.

For a binary outcome, define a variable such as Yi = 1 if customer i cancels within 60 days and Yi = 0 otherwise. For demand forecasting, define Yi,t+h as demand for unit i at future time t + h, where h is the forecast horizon.

2.3 What is the unit of analysis?

The unit of analysis is the entity or event represented by one analytical record. It may be:

  • customer;
  • transaction;
  • customer–month;
  • store–product–day;
  • machine–hour;
  • shipment;
  • account–billing cycle.

The unit must match the decision. A store manager ordering products needs store–product information, not only national totals. A customer-retention team needs customer-level predictions, not an average churn rate for the entire company.

The unit of analysis also affects sample size, aggregation, privacy risk, and possible errors. Combining transactions into monthly customer records may reduce noise but can hide short-term changes. Using individual transactions may create many observations but fail to represent the actual intervention decision.

2.4 What is the forecast horizon?

The forecast horizon is the distance into the future for which a prediction is required. Examples are one hour, seven days, one quarter, or five years.

The horizon should be determined by the decision cycle, not by convenience. It is useful to distinguish:

  • observation window: the period used to calculate explanatory information;
  • forecast origin: the time at which the prediction is made;
  • forecast horizon: the future period being predicted;
  • lead time: the time between taking an action and observing its effect.

For instance, if an order must be placed every Monday and suppliers take five days to deliver, demand may need to be forecast for the delivery period plus a safety margin. A one-day forecast may be accurate but operationally insufficient.

For a time series indexed by t, a one-step-ahead forecast is written as:

ŷt+1|t = forecast of Yt+1 made using information available through time t

A k-step-ahead forecast is:

ŷt+k|t = forecast of Yt+k made using information available through time t

The notation emphasizes that future information must not be used when making the prediction. Forecast horizons often become less accurate as they increase because uncertainty accumulates.

2.5 What information is available at prediction time?

Every predictor must be checked for temporal availability. A variable may appear in a historical database but have been recorded only after the outcome occurred. Using it would create data leakage.

For example, a customer’s “final account status” cannot be used to predict whether the customer will churn. Similarly, a retailer should not use the final monthly sales total to predict sales for that same month.

The relevant information set can be represented as It, meaning all information legitimately available at time t. A valid prediction can be expressed conceptually as:

ŷt+h|t = f(It)

where f is the forecasting or predictive procedure. The function must not use information from after t.

2.6 What action follows from the prediction?

A prediction is not automatically a recommendation. For example, a churn model may identify customers with high risk, but management still needs a policy for selecting customers, assigning offers, and measuring incremental retention.

The analytical design should specify a decision rule. A simple threshold policy is:

Action = 1 if pi ≥ τ; otherwise Action = 0

Here, p_i is the predicted probability for case i, and τ is a threshold selected according to intervention capacity and the relative costs of errors. A threshold of 0.5 is not universally correct.

2.7 What constraints must be respected?

Constraints can be technical, financial, operational, legal, and ethical. Examples include:

  • limited data history;
  • missing or delayed data;
  • small sample sizes;
  • fixed staffing or inventory capacity;
  • supplier lead times;
  • latency requirements;
  • budget limits;
  • privacy and data-protection rules;
  • fairness requirements;
  • explainability requirements;
  • restrictions on automated decisions.

Constraints should be recorded before model selection. A highly complex model may be unsuitable if the organization requires explanations, low-cost maintenance, or rapid deployment.

3. Classification of Analytical Questions

Framing improves when the analyst identifies the type of question being asked.

Descriptive questions

Descriptive analytics asks what has happened or what is happening. Examples include “Which products declined last quarter?” and “What is the current average delivery time?” Descriptive analysis is often a necessary first step but does not predict future outcomes.

Predictive questions

Predictive analytics asks what is likely to happen. Examples include “What will demand be next week?” and “Which accounts are likely to default?” Predictive performance does not prove that a variable causes the outcome.

Causal questions

Causal analysis asks what would happen if an intervention changed. Examples include “What is the effect of a discount on repeat purchases?” and “Would additional training reduce processing errors?” Correlation or predictive importance alone is insufficient to answer these questions.

Prescriptive and optimization questions

Prescriptive analysis asks what action should be taken, often under constraints. Examples include “How should inventory be allocated?” and “Which customers should receive limited retention offers?” Prescriptive decisions may use predictions as inputs but also require costs, capacities, and objectives.

Confusing these question types is a common design error. A churn model can rank risk, but it cannot establish that a retention offer will work unless treatment effects are studied.

4. Choosing Success Metrics

A metric should reflect how errors affect the decision. Statistical accuracy and business value are related but not identical.

Classification metrics

For binary classification, predictions can be summarized using a confusion matrix.

Actual positiveActual negative
Predicted positiveTrue positiveFalse positive
Predicted negativeFalse negativeTrue negative

Accuracy is:

Accuracy = (TP + TN) ÷ (TP + TN + FP + FN)

It is suitable only when class proportions and error costs make overall correctness meaningful. With rare events, accuracy can be misleading. A model that labels everyone “not fraud” may be highly accurate while detecting no fraud.

Precision and recall are:

Precision = TP ÷ (TP + FP)
Recall = TP ÷ (TP + FN)

Precision measures how many flagged cases are truly positive. Recall measures how many actual positives are found. The choice depends on consequences. A safety-monitoring system may prioritize recall; an expensive sales intervention may prioritize precision.

For predicted probabilities, calibration is also important. A group of cases assigned probability 0.70 should experience the outcome approximately 70% of the time over sufficiently large, comparable groups. Ranking ability and probability calibration are distinct properties.

Forecasting metrics

For actual value y_t and forecast ŷ_t, the error is:

et = yt − ŷt

Mean absolute error (MAE) is:

MAE = (1/n) × ∑|yt − ŷt|

MAE has the same units as the target and treats positive and negative errors symmetrically.

Mean squared error (MSE) is:

MSE = (1/n) × ∑(yt − ŷt)²

MSE gives greater weight to large errors and has squared units. Root mean squared error is:

RMSE = √MSE

RMSE returns to the target’s units but remains more sensitive to large errors than MAE.

Mean absolute percentage error is:

MAPE = (100/n) × ∑ |(yt − ŷt) ÷ yt|

MAPE is undefined when y_t = 0 and can be unstable when actual values are close to zero. It should not be used uncritically for intermittent or low-volume demand.

A scale-free alternative is mean absolute scaled error (MASE). Using a naïve benchmark based on in-sample one-step changes, a common form is:

MASE = mean(|et|) ÷ mean(|yt − yt−1|)

The denominator is calculated on a designated training period and must be nonzero. A MASE below 1 indicates improvement over the corresponding naïve benchmark under the stated construction.

Cost-weighted evaluation

When underprediction and overprediction have different costs, a business loss function is more appropriate than a symmetric metric. For example:

L(et) = cu × max(et, 0) + co × max(−et, 0)

where e_t = y_t − ŷ_t, c_u is the cost per unit of underprediction, and c_o is the cost per unit of overprediction. This formulation assumes that positive error represents underprediction and that costs are approximately linear over the relevant range.

Metrics should be agreed with stakeholders before results are reviewed. Otherwise, teams may select the metric that makes a model appear strongest.

5. Baselines, Splitting, and Validation Design

A model should be compared with a simple benchmark. In forecasting, a naïve forecast may be:

ŷt+1|t = yt

This is appropriate as a benchmark when the most recent observation is a reasonable reference, but it is not universally optimal. Seasonal naïve forecasts may use the value from the corresponding previous season.

Randomly splitting time series records into training and test sets can allow future patterns to influence model development. Time-ordered validation is generally more appropriate. A typical design trains on an earlier period, validates on a later period, and tests on the most recent untouched period.

Rolling-origin evaluation repeatedly moves the forecast origin forward. At each origin, the model uses only information available at that time. This better represents deployment and reveals whether performance changes across seasons or market conditions.

For customer-level classification, splitting must also consider repeated records. If the same customer appears in both training and test data, performance may be overstated. Grouped or time-based splits may be needed.

6. Stakeholder and Governance Design

Stakeholder analysis is not a communication exercise added after modeling. It is part of analytical validity.

StakeholderRelevant concern
Executive sponsorFinancial value and strategic alignment
Operational managerTiming, capacity, and usability
Data ownerData definitions, access, and quality
AnalystStatistical validity and reproducibility
Compliance officerPrivacy, legal basis, and auditability
Front-line usersInterpretability and workflow fit
Affected customers or employeesFairness, transparency, and recourse

A project charter should document the problem owner, decision owner, target definition, data sources, forecast horizon, evaluation metrics, constraints, risks, and deployment plan.

Ethical and regulatory considerations

Predictive systems can reproduce historical discrimination, use sensitive information improperly, or encourage harmful interventions. Good practice includes:

  • collecting only data necessary for the stated purpose;
  • documenting legitimate data use and retention rules;
  • checking performance across relevant groups;
  • distinguishing protected characteristics from permissible operational variables;
  • providing explanations appropriate to the audience;
  • preserving human review for high-impact decisions;
  • monitoring drift and unintended consequences;
  • allowing correction, appeal, or escalation where appropriate.

Fairness cannot be reduced to one universal metric. Different fairness criteria may conflict, especially when base rates differ between groups. The appropriate assessment depends on the decision, legal context, and potential harm.

7. A Practical Analytical Design Workflow

A disciplined workflow can be organized into nine stages:

  1. Clarify the decision: identify who will act, what action is possible, and when it must occur.
  2. Define the outcome: specify the target, unit, time window, and measurement rules.
  3. Define the prediction origin: identify the latest information legitimately available.
  4. Choose the horizon: align the future period with lead time and operational cycles.
  5. Map data and constraints: document sources, quality, access, latency, privacy, and capacity.
  6. Select baselines and metrics: include simple benchmarks and business-relevant measures.
  7. Design validation: preserve time order, prevent leakage, and represent deployment conditions.
  8. Plan action and monitoring: define thresholds, ownership, feedback, drift checks, and retraining.
  9. Review with stakeholders: confirm that the design answers the actual business need.

This workflow is iterative. A data audit may reveal that the target is not reliably measured. A stakeholder workshop may show that the forecast is needed weekly rather than monthly. Such discoveries should lead to reframing, not silent technical adjustments.

Worked Example: Retail Demand Forecasting

A convenience retailer experiences frequent stock-outs of chilled drinks. Management asks for “an AI forecasting system.”

Initial framing

The initial request is too broad. The analyst asks:

  • What decision is being improved? Store replenishment orders.
  • What is the target? Units sold or true demand during the replenishment period.
  • What is the unit? Store–product–day, possibly aggregated to store–product–order cycle.
  • What is the horizon? Five days, reflecting supplier lead time.
  • What information is available? Historical sales, promotions known in advance, calendar effects, weather forecasts available at order time, and inventory records.
  • What are the constraints? Refrigerated capacity, minimum order quantities, supplier schedules, and limited staff time.
  • How is success measured? Forecast error plus stock-out and waste costs.

Important complication

Observed sales may be lower than true demand when the product was out of stock. If the store sold 20 units but customers would have bought 30, treating 20 as true demand can teach the model that stock-outs are low-demand periods. The team must therefore distinguish observed sales from censored demand, using availability records, substitution information, or carefully defined assumptions.

Candidate design

The first production version forecasts five-day demand for each store–product combination. A seasonal naïve model and a simple moving-average benchmark are established before testing more complex models. Evaluation uses MAE and a cost-weighted loss that assigns a larger cost to stock-outs than to moderate excess inventory.

Suppose the five-day actual demands in a test sample are 100, 80, and 120 units, while forecasts are 90, 100, and 110 units. The errors are 10, −20, and 10 units. The MAE is:

MAE = (|10| + |−20| + |10|) ÷ 3 = 40 ÷ 3 ≈ 13.33 units

The result means that the average absolute forecast error is approximately 13.33 units for this small sample. It does not by itself show whether inventory costs improved; operational outcomes must also be monitored.

Action design

The forecast is combined with inventory position and supplier lead time to recommend an order quantity. The recommendation is not automatically accepted: store managers can override it when local events or data problems are known. Overrides are recorded so that the team can distinguish useful expert knowledge from systematic model weakness.

Outcome and learning points

In this illustrative case, the project succeeds only when the team addresses target contamination, timing, cost asymmetry, and workflow integration. An accurate forecast that arrives after the supplier cut-off would not solve the problem. The central lesson is that analytical design is a socio-technical process, not merely model selection.

Technology, AI, and Contemporary Practice

Modern platforms can automate feature generation, model comparison, and monitoring, but automation does not replace problem framing. AutoML may optimize a selected metric while ignoring business costs, leakage, fairness, or deployment restrictions.

Machine learning systems also require operational controls:

  • versioned data and model artefacts;
  • reproducible training procedures;
  • documented feature definitions;
  • monitoring of input quality and prediction distributions;
  • drift detection;
  • alert thresholds and escalation paths;
  • secure access and audit logs.

Generative AI can assist with documentation, query drafting, and stakeholder communication, but generated outputs must be checked against source data and organizational policy. It should not be treated as an independent authority for target definitions, regulatory interpretation, or high-impact decisions.

Common Failure Modes and Best Practices

Failure: vague target definitions

“Customer value” or “demand” may mean different things to different teams.

Best practice: write an operational definition with time window, unit, source, and exclusions.

Failure: optimizing a technical metric only

A small RMSE improvement may have no financial benefit.

Best practice: connect evaluation to costs, capacity, and action outcomes.

Failure: leakage

Information generated after the forecast origin enters the predictors.

Best practice: create a point-in-time data specification and audit each feature’s availability.

Failure: random validation of temporal data

Future conditions influence model development.

Best practice: use chronological or rolling-origin validation.

Failure: ignoring baselines

A complex model is accepted without proving incremental value.

Best practice: compare against naïve, seasonal, or current-practice benchmarks.

Failure: no deployment owner

The model produces predictions but nobody is responsible for acting on them.

Best practice: assign decision ownership, define workflows, and monitor realized outcomes.

Failure: treating prediction as causation

A high-risk customer may not respond to an intervention.

Best practice: use experiments or causal designs when the question concerns treatment effects.

Chapter Summary

Business problem framing translates an organizational concern into a decision-focused analytical design. The design must specify the decision, target variable, unit of analysis, forecast origin, horizon, available information, constraints, and success metrics. Predictive, causal, descriptive, and prescriptive questions require different methods and interpretations.

Metrics should reflect the consequences of errors. Classification requires attention to imbalance, precision, recall, and calibration. Forecasting commonly uses MAE, RMSE, MAPE with caution, and scaled or cost-weighted measures. Time-based validation and leakage prevention are essential for realistic performance estimates. Baselines establish whether complexity adds value.

Stakeholders, governance, privacy, fairness, explainability, and operational ownership are integral to analytical quality. The best predictive system is not necessarily the most complex; it is the system that produces timely, trustworthy information that improves a defined decision under real constraints.

Key Terms

Target variable: The outcome a model is designed to predict or estimate.

Unit of analysis: The entity or event represented by one analytical record.

Forecast horizon: The distance into the future covered by a prediction.

Forecast origin: The time at which a forecast is generated.

Observation window: The period used to construct information for a prediction.

Lead time: The delay between initiating an action and observing its effect or receiving a result.

Data leakage: Use of information unavailable at prediction time or generated after the outcome.

Baseline: A simple benchmark used to judge whether a model adds value.

Classification: Prediction of categories or class membership.

Regression: Prediction of a numerical quantity.

Forecasting: Prediction of future values indexed by time.

Precision: The proportion of predicted positives that are actual positives.

Recall: The proportion of actual positives that are correctly identified.

Calibration: Agreement between predicted probabilities and observed frequencies.

MAE: Mean absolute error, measured in the target’s units.

RMSE: Root mean squared error, sensitive to large errors.

Causal question: A question about the effect of an intervention or change.

Prescriptive analytics: Analysis that recommends actions under objectives and constraints.

Concept drift: Change in the relationship between inputs and outcomes over time.

Decision rule: A specified method for converting predictions into actions.

Review Questions

Short Answer Questions

  1. What is the difference between a business problem and an analytical problem?
  2. Define the unit of analysis and give one business example.
  3. Why must a forecast horizon reflect the decision cycle?
  4. What is data leakage?
  5. Why can accuracy be misleading for rare-event classification?

Long Answer Questions

  1. Explain how a managerial concern can be translated into a complete analytical problem statement.
  2. Compare descriptive, predictive, causal, and prescriptive analytical questions.
  3. Discuss the differences between MAE, RMSE, MAPE, and cost-weighted loss.
  4. Explain why chronological validation is generally appropriate for time series forecasting.
  5. Discuss the governance and ethical issues that should be addressed before deploying a predictive system.

Analytical / Application Questions

  1. A bank wants to reduce loan defaults. Design the target variable, unit of analysis, forecast horizon, decision rule, and at least two evaluation metrics. Explain your choices.
  2. A retailer forecasts demand using end-of-month sales totals to make decisions on the first day of that same month. Identify the likely leakage problem and propose a valid redesign.
  3. A hospital predicts next-day emergency arrivals, but the forecast is produced after staff rosters are finalized. Explain why the system has limited decision value and redesign the operational workflow.

Multiple Choice Questions with Answers

Question 1

Which statement best describes a target variable?

A. The entity represented by each row of data

B. The outcome the model is intended to predict

C. The time allowed for a manager to act

D. The software used to train a model

Correct Answer: B. The outcome the model is intended to predict

Question 2

A supplier requires five days to deliver an order. Which factor is most important when selecting a demand forecast horizon?

A. The programming language used

B. The model’s number of parameters

C. The operational lead time and decision cycle

D. The number of columns in the dataset

Correct Answer: C. The operational lead time and decision cycle

Question 3

Which situation is an example of data leakage?

A. Using last month’s sales to forecast next month’s sales

B. Using a promotion known before the forecast is made

C. Using a customer’s final cancellation status to predict cancellation

D. Using a calendar holiday indicator

Correct Answer: C. Using a customer’s final cancellation status to predict cancellation

Question 4

Which metric is expressed in the same units as the forecasted target?

A. MAE

B. MSE

C. MAPE

D. Accuracy

Correct Answer: A. MAE

Question 5

Why can accuracy be inappropriate for a rare-event classification problem?

A. It cannot be calculated for binary outcomes

B. A model can appear accurate by predicting the majority class only

C. It always penalizes false positives more than false negatives

D. It measures only numerical forecasting errors

Correct Answer: B. A model can appear accurate by predicting the majority class only

Question 6

What is the principal purpose of a baseline model?

A. To guarantee regulatory approval

B. To replace stakeholder consultation

C. To provide a simple benchmark for incremental value

D. To eliminate the need for validation

Correct Answer: C. To provide a simple benchmark for incremental value

Question 7

Which analytical question is causal?

A. Which customers are likely to churn?

B. What was last quarter’s revenue?

C. What will demand be next week?

D. What is the effect of a discount on repeat purchases?

Correct Answer: D. What is the effect of a discount on repeat purchases?

Question 8

For actual values 100, 80, and 120 and forecasts 90, 100, and 110, what is the MAE?

A. 10 units

B. 13.33 units approximately

C. 20 units

D. 40 units

Correct Answer: B. 13.33 units approximately

Question 9

Which validation design is generally most appropriate for a time series?

A. Randomly mixing all observations before splitting

B. Using only the first observation for testing

C. Preserving chronological order or using rolling origins

D. Testing on observations from before training

Correct Answer: C. Preserving chronological order or using rolling origins

Question 10

What does calibration assess in a probabilistic classifier?

A. Whether predicted probabilities correspond to observed frequencies

B. Whether the model has the lowest possible training error

C. Whether all predictors have identical units

D. Whether the forecast horizon is long enough

Correct Answer: A. Whether predicted probabilities correspond to observed frequencies

Predictive Analytics and Time Series Forecasting
Chapter 2 of 15