Diagnosing a 15% Monthly Rise in Batch Job Turnaround Time
Statistics & ExperimentsModel answerLast updated
A key operational duration metric rose 15% month over month; explain how you would find the root causes with data and what actions you would recommend.
Scenario
You are an analyst at a company that runs payroll for small and mid-sized businesses. In a review with a senior analyst, you are told:
"Average end-to-end payroll processing time is up 15% compared with last month."
Nobody yet knows why, and you are asked to take ownership of the investigation.
Task
Walk through how you would use data to find the root causes and what you would recommend afterward. A strong answer covers:
- How you would pin down what the metric means and decide whether the increase is real.
- Which hypotheses you would form and how you would group them.
- Which datasets you need and which cuts of the data you would run (time, geography, product tier, and so on).
- The order in which you would carry out the investigation.
- How you would turn the findings into fixes or experiments, including how you would measure success and avoid side effects.
State your assumptions explicitly, and mention edge cases that could make the change look bigger or smaller than it really is.
Hints
Hint 1
Before analyzing anything, ask what the start and end events are, whether the 15% is a mean or a median, and whether the two months contain different numbers of business days or holidays.
Hint 2
Rule out measurement problems (logging changes, duplicates, runs still in progress) and then split total time into its stages to see which one accounts for most of the increase.
Hint 3
Separate mix shift (a different customer or payroll composition) from rate change (the same kind of payroll getting slower), and tie every proposed fix to a diagnosed cause with a guardrail metric.
Model answer
Medium Try it yourself first — then compare your approach, complexity and edge cases.
Framing
This is a metric-diagnosis case. The goal is to move from "the number went up" to "here is what changed, how much each cause contributes, and what we should do." I would work as a funnel: validate, decompose, segment, localize, quantify, act.
1. Clarify the metric and the change
Ask these before touching data:
- Definition. Processing time could mean submit-to-approve, approve-to-debit, submit-to-employees-paid, or internal compute time. Fix the start and end events. End to end, the pipeline likely spans submission, risk review, tax calculation, bank debit, and disbursement.
- Statistic. Is the 15% a mean or a median? A rising mean with a flat median points to a small tail of stuck runs. A rising median points to a broad slowdown. Request p50, p90, and p99.
- Clock. Is time measured in wall-clock or business hours? A month with a holiday or a weekend-heavy window can look slower without any real change.
- Baseline. Is 15% outside normal month-over-month variance? Look at 12 to 24 months and the same month last year, since quarter-end and year-end carry heavy tax-filing load.
2. Rule out artifacts first
- Instrumentation. Were timestamps, event names, or the "start" event changed recently? Check the release and feature-flag log.
- Data quality. Look for duplicate run IDs, late-arriving events, and null end timestamps.
- Censoring. If the month just closed, fast runs have finished but slow ones may still be open. Compare like-for-like cohorts (for example, runs submitted in the same window and observed for the same duration) or use survival-style estimates.
- Calendar. Recompute in business hours. If the delta mostly vanishes, this is a reporting issue, not an operational one.
3. Decompose
By stage. Total time is the sum of stage durations:
T = T_submit→approve + T_risk_review + T_tax_calc + T_bank + T_disburse
Compute the month-over-month change for each stage. Usually one or two stages explain most of the increase, which sharply narrows the hypotheses.
By mix versus rate. The overall average is a weighted average over segments, T̄ = Σ wᵢ·tᵢ, where wᵢ is the share of runs in segment i and tᵢ its average time. The change splits as:
ΔT̄ = Σ Δwᵢ·tᵢ⁰ (mix effect) + Σ wᵢ¹·Δtᵢ (rate effect)
- Mostly mix: nothing got slower; we are processing inherently more complex payrolls (new customers, multi-state employers, larger companies).
- Mostly rate: something degraded within segments, such as a queue backlog, a code regression, or a partner issue.
Stating this distinction explicitly is one of the strongest signals in this kind of case.
4. Hypotheses
| Category | Hypothesis | Evidence |
|---|---|---|
| Calendar | Holidays, fewer business days, period-end load | Delta shrinks in business hours |
| Customer mix | More new, larger, or multi-state customers | Mix effect dominates; new-customer cohort slower |
| Product | New tier or feature adds steps | Slowdown concentrated in one tier or flag |
| Operations | Review queue backlog, staffing gap | Wait time grows in review stage; queue depth up |
| Engineering | Deploy slowed tax calc; third-party latency | Step change at deploy date; service latency up |
| Partners | Bank/ACH or state agency delays | Concentrated by bank or state |
| Customer behavior | Late submissions, more edits and reruns | Submit-to-approve grows; more corrections |
5. Data needed
- Payroll run table: run ID, company ID, timestamp per stage, status, headcount, states, run type (regular, off-cycle, correction).
- Company dimension: tier, signup date, size, industry, states.
- Operations data: review queue depth, staffing, ticket volume.
- Engineering data: deploys, feature flags, service latency, error and retry rates.
- Partner data: bank return codes, agency incidents.
- Calendar table: business days, holidays, period-end flags.
6. Cuts
- Time: daily and weekly trend. A step change suggests a release or policy change; a gradual drift suggests growth or capacity limits. Check day-of-week and pre-holiday effects.
- Geography: state, and single versus multi-state.
- Product tier and add-ons.
- Customer: tenure, size, first run versus repeat.
- Run type: regular, off-cycle, correction.
- Distribution: median versus tail, and whether a few large customers dominate.
7. Investigation sequence
- Validate definitions, instrumentation, censoring, and calendar. Re-express in business hours.
- Check whether the shift is in the median or only the tail.
- Decompose by stage and find the dominant one.
- Run the mix-versus-rate split.
- Drill into the culprit segment and stage; overlay deploys, staffing, and partner incidents on the time series.
- Attribute the 15%, for example: "about 6 points calendar, 5 points review backlog from a new-customer surge, 4 points tax-calc latency after a specific deploy." Numbers like these should come from the data, and the attribution should sum to the total.
- Size the business impact: late payrolls, missed pay dates, support tickets, churn risk. Late paychecks are the outcome that matters most.
8. Recommendations tied to causes
- Calendar or mix only: fix the reporting, not operations. Track business-hour, mix-adjusted, and year-over-year metrics, and set alert thresholds from historical variance.
- Review backlog: add capacity short term. Longer term, A/B test auto-approval for low-risk companies by randomizing eligible runs. Primary metric is processing time; guardrails are fraud and loss rate and chargebacks.
- Engineering regression: roll back or fix. If attribution is ambiguous, use a feature-flag holdout to confirm causality.
- New-customer complexity: test onboarding improvements such as pre-validating tax setup and bank details. Randomize by new company and measure time to first payroll.
- Partner delays: add monitoring, earlier submission cutoffs, or alternate routing, and communicate expected timing to customers.
Trade-offs and common mistakes
- Speeding up review can raise fraud risk, so always pair speed targets with a risk guardrail.
- Do not treat a mean increase as a broad slowdown without checking the tail.
- Do not skip censoring: an unfinished month biases durations in either direction.
- Do not stop at correlation with a deploy; check the timing and use a holdout where possible.
- Avoid a single-cause story. Real increases are often several small causes stacked together.
- Finish with a monitoring plan: a stage-level dashboard, a mix-adjusted metric, and alerts on p90, so the next change is caught within days instead of a month.