Senior Engineering CraftVol. 24 · Craft
0 / 0

Shelves / Senior Engineering Craft

SC·03

Estimation and Planning

Why estimates are wrong in predictable ways and how to make them useful anyway: estimates versus targets versus commitments, the skewed shape of task durations, optimism and forgotten work, decomposition, three-point ranges and reference classes, story points and their limits, forecasting from past throughput with Monte Carlo, confidence levels, buffers, milestones and dependencies, scope as the variable you control, tracking and re-forecasting, and how to answer "can it be done faster?"; with a lab that simulates a twelve-task project and a throughput forecast.

23 topics · ~11 min read · 16-question quiz
Updated Suggest a correction

Start here: twelve tasks, 29 days

Your squad breaks the Dubai launch's ordering work into twelve tasks and estimates each: 1, 2, 2, 3, 1, 5, 3, 2, 4, 1, 2, 3 days, 29 days in total. Someone writes "29 days" in the plan.

The lab simulated the project 20,000 times. Each task's actual duration was its estimate times a random factor drawn from a skewed (lognormal) distribution: tasks usually take about their estimate, sometimes a bit less, occasionally two or three times more. Two scenarios:

Assumption about each task Median total 85th percentile Chance of finishing within 29 days
estimates are unbiased (median actual = estimate) 33.8 days 42.0 days 22%
estimates are 20% optimistic (median actual = 1.2 × estimate) 40.6 days 50.4 days 5%
…plus six possible unlisted pieces of work (2 days each, 50% likely) 49.2 days 60.2 days

Even with perfectly unbiased task estimates, the sum of estimates is a poor plan: there's only a 22% chance of meeting it. That's because durations are skewed: a task can't finish in negative time, but it can take three times as long, so over-runs aren't cancelled by under-runs. Add realistic optimism and work nobody listed (integration, reviews, a migration, a security review), and "29 days" becomes a 5% bet.

The same lab forecast a backlog of 40 items from the squad's last ten weeks of throughput (3, 5, 2, 4, 6, 3, 4, 1, 5, 4 items per week): 11 weeks at 50% confidence, 13 weeks at 85%, with no item estimated at all.

The craft isn't guessing better; it's saying what you know with its uncertainty, and planning so the uncertainty doesn't hurt.

How deep to go

Volume 17 defines six mastery levels. For estimation and planning:

Level What you can do
L1 Break your own task into steps and estimate it
L2 Give ranges, flag assumptions and risks, track your estimates against actuals
L3 Estimate and plan a multi-week feature for a team, with milestones and dependencies
L4 Forecast probabilistically from data; spot plans heading for trouble early
L5 Plan multi-team projects and quarters; negotiate scope and dates with stakeholders
L6 Set planning practices for an organisation and calibrate its forecasts

Why estimate at all

Estimates support decisions: is this worth doing (cost vs value)? which first? when can marketing announce? does the Dubai launch need two squads or one? Without them, priorities are set blind. But an estimate's job is to inform a decision, not to be a promise; precision beyond what the decision needs is waste.

Keep three things apart (Steve McConnell's distinction):

What it is Example
estimate a prediction, with uncertainty "6–9 weeks, most likely 7"
target a business wish "launch before Ramadan"
commitment a promise, chosen from an estimate "we commit to the core ordering flow by 20 Feb, at ~85% confidence"

When a target and an estimate disagree, the answer is a conversation about scope, approach or risk, not a smaller estimate.

Why estimates go wrong

Durations are skewed

There are many ways a task can take longer (an unclear requirement, a flaky dependency, a hard bug, a sick day) and few ways it can take much less. So durations follow a right-skewed distribution: the most likely value is below the mean, and the tail is long. In the lab's optimistic scenario, a single 3-day task took a median of 3.6 days and a mean of 4.3 days, with a 20% chance of taking more than twice its estimate (p90: 7.8 days). Summed over many tasks, the over-runs dominate.

Systematic optimism

The planning fallacy (Kahneman and Tversky) is people's tendency to underestimate their own tasks while knowing that similar tasks took longer before. Engineers estimate the coding, imagining it going smoothly, and forget the rest.

Forgotten work

Most estimates omit work that isn't "the feature": code review rounds, tests, CI fixes, data migration, documentation, security and privacy review, translations (Volume 23), release, monitoring, bug fixes after release, meetings, on-call interruptions and holidays. A team's capacity for planned work is often 50–70% of its nominal time; measure yours.

The cone of uncertainty

At the start of a project, before requirements and design are settled, estimates can be off by a large factor in either direction; McConnell's "cone of uncertainty" illustrates ranges as wide as 4× to 0.25× at the idea stage, narrowing as decisions are made. You can't estimate your way out of early uncertainty; you reduce it by deciding things, building the riskiest part first, and running spikes.

Techniques

Decompose, then look for what's missing

Break work into pieces small enough to estimate (a day or two to a week). Then walk the checklist of forgotten work and add it explicitly. Decomposition itself often reveals unknowns ("wait, who builds the AED invoice template?").

Ranges and three-point estimates

Give each piece a range: optimistic (O), most likely (M), pessimistic (P). PERT's formula approximates the mean as (O + 4M + P) / 6. Summing ranges correctly needs simulation (the lab), but even without it, ranges communicate uncertainty and force you to think about what could go wrong.

Reference classes

Ask "how long did similar things take us before?" A reference class of past projects (outside view) corrects the optimism of a bottom-up plan (inside view). Keep a simple log of planned vs actual for your team's projects; after a year it's the best estimating tool you have.

Spikes

When uncertainty is concentrated in one question ("can CDC keep up with our write volume?"), spend a time-boxed spike (a day or three) to answer it before estimating the rest.

Relative sizing and story points

Many agile teams estimate in story points: relative sizes ("this is about twice that") rather than days, then track velocity (points per sprint). It can work as a team's private shorthand and for spotting misunderstandings ("why did you say 8 when I said 2?"), as in Planning Poker. It goes wrong when points are converted back to hours, compared across teams, or used as productivity targets: then they inflate. Points are a tool for conversation, not a currency.

Forecasting from throughput

An alternative, sometimes called #NoEstimates: split work into small items of roughly similar size, count how many items the team finishes per week, and forecast with Monte Carlo by sampling past weeks' throughput until the backlog is done, many times. The lab's 40-item forecast took seconds: 11 weeks at 50%, 13 weeks at 85%, against a naive average of 10.8 weeks. Its strength is that it uses what the team actually delivered, including all the forgotten work and interruptions. Its weakness: it needs history, and assumes the future backlog resembles the past (new kinds of work need a spike or a reference class).

From estimate to plan

  • Choose a confidence level for commitments: P50 for internal planning, P80–P90 for external promises.
  • Hold buffers at the project level, visible to everyone, not hidden in each task, where they're consumed by Parkinson's law (work expands to fill the time available) and student syndrome (starting late).
  • Milestones every few weeks with demonstrable outcomes ("a Dubai test user can order and pay in AED"), so progress is checked by working software, not percentages.
  • Dependencies and the critical path: identify work that waits on other teams or vendors; start those first, and track them weekly. Most late projects are late on a dependency.
  • Build the riskiest part first: the unknowns shrink fastest when you attack them.
  • Fixed date, variable scope: when the date really can't move (Ramadan, a regulatory deadline, a conference), rank scope by value (MoSCoW: must, should, could, won't) and deliver in that order so that what's cut is the least valuable.
  • Rolling-wave planning: plan the next few weeks in detail and later phases roughly, refining as you go.

Tracking and re-forecasting

  • Track finished work (burn-up charts: done vs total scope), not hours spent. A burn-up shows scope growth as well as progress.
  • Re-forecast regularly from actual throughput; report the new range with what changed.
  • Raise bad news early: a slip announced at week 3 has options (scope, staffing, sequencing); the same slip announced in the last week has none.
  • Compare estimates with actuals after each project, without blame, to calibrate.

Communicating estimates

Say the range, the confidence, and the assumptions:

"Core ordering for Dubai: 6–9 weeks; I'd commit to 9 weeks at about 85% confidence. That assumes the payment provider's sandbox is ready by week 2 and Arabic translations arrive by week 5. If either slips, the range moves by about the same amount. To be confident of 7 weeks we'd drop scheduled orders from the first release."

When asked "can you do it faster?":

  1. Ask what matters: the date, a specific feature, or a signal to customers?
  2. Offer options with trade-offs: cut scope, change approach, accept specific risks, add people early to separable work.
  3. Don't just lower the number. If leadership chooses a date below your estimate, record it as a target with stated risk.

Brooks's law ("adding manpower to a late software project makes it later") holds because new people need onboarding and coordination grows with team size. Adding people helps when it's early, the work splits cleanly, and the newcomers know the domain.

Common traps

  • Single-number estimates, especially summed.
  • Estimates treated as commitments, or negotiated down.
  • Forgetting non-coding work and interruptions.
  • Padding every task instead of a visible project buffer.
  • Story points as a productivity metric.
  • Leaving the riskiest work for last.
  • Reporting "90% done" instead of finished milestones.
  • Hiding slips until the end.

Lab: simulating a plan

Setup. Two Python 3.13 scripts using only the standard library, with a fixed random seed. This is a simulation: its inputs are assumptions chosen to be realistic, not measurements of a real team.

  • Task model. Twelve tasks estimated at 1, 2, 2, 3, 1, 5, 3, 2, 4, 1, 2, 3 days (29 in total). Each simulated actual duration = estimate × a lognormal factor with σ = 0.6 (so a task's 80% range is roughly 0.45× to 2.2× its median), with the median factor either 1.0 (unbiased) or 1.2 (20% optimistic). A third variant adds six possible unlisted pieces of work, each 50% likely and estimated at 2 days. 20,000 runs each.
  • Throughput model. The team's finished items per week over ten past weeks: 3, 5, 2, 4, 6, 3, 4, 1, 5, 4. Each run samples a past week at random, repeatedly, until 40 items are done, and records the weeks needed. 20,000 runs.

Results

Scenario p10 p50 p85 p95 P(≤ 29 days)
unbiased tasks 33.8 42.0 22%
20% optimistic tasks 31.3 40.6 50.4 57.6 5%
optimistic + unlisted work 49.2 60.2
  • One 3-day task (optimistic): median 3.6, mean 4.3, p90 7.8 days; 20% chance of exceeding 6 days.
  • Throughput forecast for 40 items: p50 11 weeks, p85 13 weeks, p95 13 weeks; naive 40 ÷ mean throughput (3.7/week) = 10.8 weeks.

What it shows

  • Summing estimates gives a low-probability date, even if every estimate is unbiased, because skewed over-runs don't cancel out.
  • Small biases compound: 20% optimism per task cut the chance of meeting the sum from 22% to 5%.
  • Unlisted work moves the median more than any single task: listing it is the cheapest accuracy improvement.
  • Throughput forecasts are quick and grounded in what the team actually finished, and give a range for free.
  • The numbers depend on the assumptions: σ, bias and the throughput history are inputs. Use your team's own history to choose them.

Try it yourself

  1. Change σ to 0.3 and 0.9 and see how the p85 moves relative to the sum.
  2. Record estimates and actuals for your next ten tasks; fit the ratio's median and spread, and rerun the model with them.
  3. Pull your team's weekly finished-item counts for the last quarter and forecast your current backlog.
  4. Add a dependency: task 6 can't start until an external team delivers, with delivery uniformly between day 5 and day 20. How does the p85 change?
  5. Rewrite a recent single-number estimate you gave as a range with confidence and assumptions.

Revision sheet: estimation and planning

Key ideas

  • Estimates inform decisions; keep estimates, targets and commitments separate.
  • Error sources: right-skewed durations, the planning fallacy, forgotten work, early uncertainty (the cone).
  • Techniques: decomposition plus a forgotten-work checklist, ranges/three-point, reference classes, spikes, relative sizing as conversation, throughput forecasting with Monte Carlo.
  • Plans: a stated confidence for commitments, project-level buffers, milestones as working software, dependencies first, riskiest work first, fixed date with variable scope, rolling-wave detail.
  • Track finished work (burn-up), re-forecast, raise slips early, calibrate against actuals.
  • Communicate ranges, confidence and assumptions; answer "faster?" with options.

Numbers to remember

  • Lab: sum of 29 days met only 22% (unbiased) or 5% (20% optimistic) of the time.
  • Throughput forecast: 40 items → p50 11, p85 13 weeks.
  • Capacity for planned work is often 50–70% of nominal time.

Glossary

  • Planning fallacy: optimism about one's own durations.
  • Reference class forecasting: estimating from outcomes of similar past projects.
  • PERT estimate: (O + 4M + P) / 6.
  • Spike: a time-boxed investigation.
  • Throughput: items finished per period.
  • Burn-up chart: cumulative finished work against total scope.
  • Brooks's law: adding people to a late project makes it later.
  • MoSCoW: must, should, could, won't.