<DataInsights />
  • 🏠 Home
  • 📊 SQL
  • 🐍 Python
  • 📈 Power BI
  • 📗 Excel
  • 💼 Career
  • 🎯 Interview Q&A
  • 📁 Case Study
  • 📥 Downloads
  • 🚀 My Portfolio
<DataInsights />

Practical Data Analytics tutorials covering SQL, Python, Power BI, Excel and career guidance for aspiring analysts — 100% free.

Topics

  • SQL Tutorials
  • Python Guide
  • Power BI
  • Excel Tips
  • Career Guide

Quick Links

  • 🛠️ All Tools
  • 🗓️ Archive
  • 📬 Contact
  • 🔍 Search
  • Portfolio
  • Kaggle
  • GitHub

Legal & Info

  • About
  • Contact
  • Privacy Policy
  • Disclaimer
  • Terms & Conditions
  • DMCA
  • Sitemap
Copyright © 2026 Data Insights by Jatin Kumar. All Rights Reserved.Built with ❤️ for Data Analysts
Home/Data Analytics/Supply Chain Analytics — Formulas & Case Studies...

Supply Chain Analytics — Formulas & Case Studies

A
September 2, 2026 Jatin Kumar 14 min read Data Analytics
Data Insights — Supply Chain Analytics

Supply Chain Analytics — Formulas & Case Studies

OTIF, Fill Rate, RTO, Safety Stock, EOQ, Inventory Turnover, MAPE aur Bullwhip Effect — complete formula sheet with worked case studies. Metric decomposition trees, must-know SCM terms aur practice question bank. Supply Chain Analyst interview ready.

📑 Is Article Mein Kya Hai:

  • 🧭 PART 0 — Case Study Answer Karne ka FRAMEWORK
  • 📐 PART 1 — Complete Formula Sheet
  • 🎯 PART 2 — Worked Case Studies
  • 🌳 PART 3 — Metric Decomposition Trees
  • 🗣️ PART 4 — Must-Know SCM Terms
  • 📋 PART 7 — Case Study Question Bank (Practice karo)
  • ✅ PART 8 — Quick Revision (Interview se 1 ghanta pehle)

🧭 PART 0 — Case Study Answer Karne ka FRAMEWORK

Har case study me yeh 5 steps follow karo. Interviewer structure dekh ke impress hota hai, answer se zyada.

STEP 1  CLARIFY   →  "Kya yeh OTIF order-level hai ya line-level?"  (1-2 question poocho)
STEP 2  DECOMPOSE →  Metric ko formula me todo (OTIF = On-Time × In-Full)
STEP 3  HYPOTHESIZE → 3-4 possible reasons bolo (MECE — no overlap)
STEP 4  VALIDATE  →  Data slice karo — "main COD vs Prepaid split karunga"
STEP 5  RECOMMEND →  Impact + Effort ke hisaab se prioritise karo, ROI batao

🔑 Golden Rule

Metric ka formula pehle bolo. Agar Fill Rate = Units Delivered / Units Ordered bol diya, toh aadha case wahi solve ho gaya — kyunki ab pata hai numerator dekhna hai ya denominator.

📐 PART 1 — Complete Formula Sheet

1.1 Delivery / Service Metrics

MetricFormulaGood benchmark
OTIFOn-Time AND In-Full lines ÷ Total lines> 95%
On-Time Delivery (OTD)On-time shipments ÷ Total shipments> 95%
Fill Rate (Line)Lines filled complete ÷ Total lines> 97%
Fill Rate (Unit)Units delivered ÷ Units ordered> 98%
Perfect Order %On-time × In-full × Damage-free × Correct docs> 90%
SLA Breach %Breached ÷ Total< 5%
Average TATΣ(delivery date − order date) ÷ ordersCategory dependent
First Attempt Delivery %Delivered in 1st attempt ÷ Total> 85%

🚨 OTIF vs Fill Rate — verified math

Total order lines          = 1000
In-full lines              =  920  →  Line Fill Rate = 92.00%
On-time lines              =  850  →  On-Time Rate   = 85.00%
On-time AND In-full lines  =  780  →  OTIF           = 78.00%

Key insight: OTIF (78%) hamesha min(On-Time, In-Full) se kam hoga — kyunki yeh intersection hai, average nahi. Interview me yeh line bolna = tumhe concept clear hai.

🏆 The Classic: "Fill Rate 97%, OTIF 82% — kya problem hai?"

Fill Rate 97%  →  inventory availability THEEK hai, stock-out nahi hai
OTIF    82%    →  bottleneck ON-TIME component me hai

Answer:

"Sir, Fill Rate 97% matlab warehouse me stock maujood hai — availability issue nahi hai.
OTIF 82% matlab problem On-Time side me hai. Main milestone TAT breakdown karunga:
Order-to-Dispatch TAT → Dispatch-to-Hub → Hub dwell time → Last-mile SLA breach.
Jis stage pe sabse zyada variance milega, wahi root cause hai."

RCA dimensions:

  • Hub-wise SLA breach rate (top 5 hubs)
  • Rider capacity vs assigned shipments
  • Pincode clustering (remote areas)
  • Time-of-day dispatch (peak hour backlog)
  • Weather / festival spike days

1.2 Inventory Metrics ⭐

MetricFormulaVerified example
Days of Stock (DOS)Current Stock ÷ Avg Daily Sales45 ÷ 9 = 5.00 days
Days of Inventory (DOH)365 ÷ Inventory Turnover365 ÷ 8 = 45.62 days
Inventory TurnoverCOGS ÷ Avg Inventory Value12,00,000 ÷ 1,50,000 = 8.00x
Reorder Point (ROP)(Avg Daily Sales × Lead Time) + Safety Stock9×10 + 54.4 = 144.4
Safety StockZ × σ(demand) × √Lead Time1.64 × 12.5 × √7 = 54.4
EOQ√(2 × D × S ÷ H)√(2×12000×500÷60) = 447.2
Stock-out RateLost sales ÷ Total demand
Shrinkage %(Book stock − Physical stock) ÷ Book stock
Inventory Accuracy %Correct SKUs ÷ Total SKUs countedTarget 99%+ (example value — yeh tera personal result NAHI hai)
Carrying Cost %(Holding + Insurance + Obsolescence) ÷ Inventory Value20–30%/yr

Service Level → Z-score (verified)

Service LevelZ-scoreSafety Stock (σ=12.5, LT=7)
90%1.28242.4 units
95%1.64554.4 units
97%1.88162.4 units
99%2.32676.9 units
💡 Trade-off answer: "Service level 95% se 99% karne pe safety stock 41% badh jata hai
(54.4 → 76.9). Isliye main ABC-wise differentiated service level rakhta hoon —
A items 99%, B items 95%, C items 90%."

EOQ Sensitivity (verified — yeh table interview me gold hai)

Order QtyOrders/yearTotal Cost
30040.0₹29,000
40030.0₹27,000
447 (EOQ)26.8₹26,833 ← minimum
50024.0₹27,000
60020.0₹28,000

Insight: EOQ curve flat hota hai — ±20% deviation pe cost sirf ~0.6% badhta hai. Isliye practical me MOQ (Minimum Order Quantity) aur truck-load constraints ke saath adjust karte hain.

1.3 Cost Metrics

MetricFormulaVerified
Landed CostItem + Freight + Duty + Handling + Insurance500+60+45+25 = ₹630
Cost per DeliveryTotal logistics cost ÷ Deliveries9,00,000 ÷ 10,000 = ₹90
Cost per AttemptTotal cost ÷ Total attempts9,00,000 ÷ 11,300 = ₹79.6
Cost per Order (CPO)Fulfillment cost ÷ Orders
Cost as % of RevenueLogistics cost ÷ Revenue × 100
Wasted on failed attemptsFailed attempts × Cost per attempt1,300 × 79.6 = ₹1,03,540

1.4 Returns / RTO

MetricFormula
Return RateReturned orders ÷ Total orders
RTO %RTO orders ÷ Total orders
RTO CostRTO count × (Forward freight + Reverse freight + Handling)
Refund TATAvg days from delivery-fail to refund

1.5 Warehouse Ops

MetricFormulaVerified
Lines per HourLines picked ÷ Labor hours3,200 ÷ 40 = 80 LPH
Pick AccuracyCorrect picks ÷ Total picks
Dock-to-Stock TimeReceiving to putaway hours
Space UtilizationUsed slots ÷ Total slots
Order Cycle TimeOrder received → shipped

1.6 Forecast Accuracy ⭐

MetricFormulaVerified example
MAPEavg(\Actual−Forecast\
MADavg(\Actual−Forecast\
Biasavg(Forecast − Actual)+0.0 (unbiased)
RMSE√(avg((A−F)²))Penalises big errors
WAPEΣ\A−F\
Actual   = [1000, 1200,  900, 1100, 1300]
Forecast = [1050, 1100,  950, 1000, 1400]
MAPE = 7.13%   MAD = 80.0   Bias = 0.0
Interview line: *"MAPE tab misleading hota hai jab actual values bahut chhoti ho —
isliye main WAPE use karta hoon. Aur Bias check karta hoon: agar consistently positive hai
matlab hum over-forecast kar rahe hain, jisse excess inventory banegi."*

1.7 Bullwhip Effect (verified)

Customer demand  CV = 0.043
Retailer order   CV = 0.053
Factory order    CV = 0.056
Variance amplification (retail demand → factory order) = 1.46x

Causes: demand signal processing, order batching, price fluctuation, rationing/shortage gaming Fixes: information sharing (POS data), EDI/API integration, VMI, smaller batch sizes, EDLP (Everyday Low Pricing), reduce lead time

🎯 PART 2 — Worked Case Studies

CASE 1 — Fill Rate 97% but OTIF 82% ✅ (see Part 1.1)

CASE 2 — RTO 8% → 21% after Big Billion Days (Flipkart)

Context: Har RTO pe ₹60–120 reverse logistics cost. Festival ke baad spike.

Step 1 — Data Slicing (yeh bolo sabse pehle)

1. Payment mode    →  COD vs Prepaid RTO rate
2. Time            →  Pre-festival vs festival vs post-festival
3. Category        →  Fashion/Apparel vs Electronics
4. Geography       →  Pincode tier (metro vs tier-3)
5. Delivery TAT    →  SLA breach vs on-time
6. Rider / Hub     →  Fake attempt detection
7. Order value     →  High value vs low value

Step 2 — Root Causes (MECE)

BucketCause
CustomerImpulse COD buys, buyer's remorse, address galat, ghar pe nahi tha
LogisticsPeak load pe capacity short, delivery late night, fake "customer unavailable"
ProductSize/color mismatch (Fashion), damaged in transit
SystemNo pre-delivery confirmation, no live tracking, no reschedule option

Step 3 — Verified Cost Impact

RTO 21% → 12% on 200,000 annual orders, ₹90 per RTO
Saving = 9% × 200,000 × ₹90 = ₹16,20,000 / year
Investment (WhatsApp confirmation + geo-fencing) = ₹4,00,000
Payback = 3.0 months     ROI = 305%

Step 4 — Recommendations (Impact × Effort matrix)

ActionImpactEffort
WhatsApp/SMS 1-click address confirmation before dispatch🔥 HighLow ⭐
COD risk scoring (new user + high value + remote pincode = friction)HighMedium
Geo-fencing on delivery scan (fake attempt block)HighMedium
Live tracking + 2-hour delivery slotMediumMedium
Reschedule option instead of RTOMediumLow ⭐
Size guide + AR try-on (Fashion)MediumHigh

CASE 3 — Hub-wise SLA Breach Spike (Flipkart/Ekart)

Task: Last 30 days me top 5 hubs with highest SLA breach.

SQL Answer ⭐ (verified — _verify/mysql_run_all.py)

SELECT s.hub_id,
       COUNT(*) AS shipments,
       ROUND(100.0 * SUM(CASE WHEN o.actual_delivery_date > o.promised_delivery_date
                              THEN 1 ELSE 0 END) / COUNT(*), 2) AS sla_breach_pct
FROM shipments s
JOIN orders o ON s.order_id = o.order_id
WHERE o.order_date >= CURDATE() - INTERVAL 30 DAY
GROUP BY s.hub_id
HAVING COUNT(*) >= 500
ORDER BY sla_breach_pct DESC
LIMIT 5;

Verified output:

hub_id  shipments  sla_breach_pct
    H1          3           66.67
    H2          2           50.00

Milestone TAT Breakdown (RCA ka core) ⭐

SELECT s.hub_id,
       ROUND(AVG(TIMESTAMPDIFF(HOUR, s.dispatch_time, s.hub_arrival_time)),1)        AS dispatch_to_hub_hr,
       ROUND(AVG(TIMESTAMPDIFF(HOUR, s.hub_arrival_time, s.out_for_delivery_time)),1) AS hub_dwell_hr,
       ROUND(AVG(TIMESTAMPDIFF(HOUR, s.out_for_delivery_time, s.delivered_time)),1)   AS last_mile_hr
FROM shipments s
GROUP BY s.hub_id
ORDER BY hub_dwell_hr DESC;

Yeh query bata dega bottleneck kahan hai:

  • dispatch_to_hub zyada → mid-mile / line-haul problem
  • hub_dwell zyada → hub sorting capacity / backlog
  • last_mile zyada → rider capacity / pincode remoteness

CASE 4 — Inventory Optimization (Amazon)

Scenario: 3,000 SKUs, kuch pe stockout, kuch pe 90+ days inventory.

Interview me bol: "Is type ke case pe maine analysis practice kiya hai."

Approach

1. ABC analysis karo (Pareto 80/95/100)
2. Har class ke liye service level set karo (A=99%, B=95%, C=90%)
3. Safety stock recalculate karo class-wise
4. EOQ/MOQ se order quantity optimise karo
5. Slow-mover (DOH > 90) identify karke liquidation plan

ABC Analysis — verified

category_name  revenue  cumulative_pct  abc_class
      Fashion  59000.0           45.31          A
  Electronics  44400.0           79.42          A
      Grocery  20800.0           95.39          C
  Accessories   6000.0          100.00          C

Insight: 2 categories (Fashion + Electronics) = 79.4% revenue — inpe focus karo. Accessories 100% cumulative pe hai but sirf ₹6,000 — inka service level kam rakho.

Stockout Risk Query (Python — verified)

df["days_of_stock"] = df["current_stock"] / df["daily_avg_sales"]
df["reorder_point"] = df["daily_avg_sales"] * df["lead_time_days"]
df["reorder_status"] = np.where(
    df["days_of_stock"] <= df["lead_time_days"],
    "Critical - Reorder Now", "Safe")

Verified output:

sku_id  current_stock  daily_avg_sales  lead_time_days  days_of_stock  reorder_point          reorder_status
    S1            120               12               7           10.0             84                    Safe
    S2             45                9              10            5.0             90  Critical - Reorder Now
    S3            300               20              14           15.0            280                    Safe
    S4              0                5               5            0.0             25  Critical - Reorder Now

CASE 5 — Fraud Detection (Mastercard)

Red Flags (professional terms me bolo) ⭐

PatternProfessional Name
Naye account se badi transactionAccount Age Velocity Anomaly / Bust-Out Fraud
Chhoti-chhoti payments phir ek badiCard Testing → Cash-Out Escalation
2–4 AM high amountOff-Hour / Temporal Anomaly
Baar-baar OTP failBrute-Force OTP Velocity / Account Takeover
Ek card, multiple devices/locationsDevice Fingerprint Mismatch / Impossible Travel
Merchant pe sudden volume spikeMerchant Collusion / Laundering

SQL (verified)

WITH transaction_velocity AS (
    SELECT card_number, transaction_id, transaction_amount, transaction_time,
           LAG(transaction_time,1) OVER (PARTITION BY card_number ORDER BY transaction_time) AS prev_time,
           AVG(transaction_amount) OVER (PARTITION BY card_number) AS avg_card_spend
    FROM transactions
)
SELECT card_number, transaction_id, transaction_amount,
       TIMESTAMPDIFF(MINUTE, prev_time, transaction_time) AS mins_gap,
       &#x27;High Risk' AS risk_flag
FROM transaction_velocity
WHERE TIMESTAMPDIFF(MINUTE, prev_time, transaction_time) <= 10
  AND transaction_amount > (3 * avg_card_spend);

🧠 Pro Insight (verified math)

Ek card pe n transactions hain toh max(txn / card_avg) kabhi (n−1) se zyada nahi ho sakta.
Matlab "5× average" rule kam se kam 6 transactions wale card pe hi fire karega.
Production me: threshold card-history size ke hisaab se dynamic rakho, ya
rolling average (last 30 txn) use karo — full-card average nahi.

CASE 6 — Warehouse Productivity (Wipro/3PL)

Lines picked  = 3,200
Labor hours   = 40
Lines per Hour (LPH) = 80

Agar travel time 55% hai:
  Productive pick time = 18 hrs
  Effective pick rate  = 178 lines/hr

Insight: "LPH improve karne ka sabse effective tareeka picker ki speed badhana nahi, travel time kam karna hai. Isliye slotting optimization karta hoon — A-class items ko golden zone (waist-height, pack station ke paas) me rakhta hoon."

🌳 PART 3 — Metric Decomposition Trees

OTIF Tree

                          OTIF %
                            │
              ┌─────────────┴─────────────┐
          On-Time %                   In-Full %
              │                           │
    ┌─────────┼─────────┐        ┌────────┼────────┐
 Order-to-  Mid-Mile  Last-Mile  Stock    Pick     Pack
 Dispatch   Transit   Delivery   Avail.   Accuracy Accuracy
    │          │         │         │        │        │
 Backlog   Line-haul  Rider cap  ROP/SS  Slotting  Label
 Pick TAT  Route plan Pincode    Forecast LASA     Scanner

RTO Tree

                          RTO %
                            │
        ┌───────────┬───────┴────┬────────────┐
    Customer      Address      Delivery      Product
        │            │            │            │
  Impulse buy   Incomplete    Late slot    Size mismatch
  COD remorse   Wrong pin     Fake attempt Damaged
  Not available No phone      Remote area  Wrong item

Inventory Cost Tree

                    Total Inventory Cost
                            │
        ┌───────────────┬───┴────────┬──────────────┐
   Ordering Cost    Holding Cost   Stockout Cost   Obsolescence
        │               │               │              │
   PO processing    Warehouse rent   Lost sales    Write-off
   Freight          Insurance        Margin loss   Markdown
   Receiving        Capital cost     Churn         Expiry (FEFO)

🗣️ PART 4 — Must-Know SCM Terms

TermMatlab
SKUStock Keeping Unit — unique product identifier
FEFO / FIFOFirst Expiry/In First Out — pharmacy/FMCG me critical ⭐
LASALook-Alike Sound-Alike — similar dikhne wali medicines ⭐
MOQMinimum Order Quantity
VMIVendor Managed Inventory
3PL / 4PLThird/Fourth Party Logistics
Cross-dockingBina storage ke direct inbound→outbound
SlottingWarehouse me item placement optimization
Golden ZoneWaist-height picking area (fastest access)
Cycle CountContinuous partial inventory audit ⭐
Bottleneck / TOCTheory of Constraints — system ka limiting step
Lead TimeOrder place → receive ka time
Safety StockBuffer against demand/lead-time variability
Bullwhip EffectDemand variance ka upstream amplification
Milk RunMultiple suppliers se ek hi vehicle me pickup
Dead StockJO sell hi nahi ho raha
WIPWork In Progress
SLAService Level Agreement
PODProof of Delivery
RTOReturn to Origin
CODCash on Delivery
AOVAverage Order Value
Landed CostItem + sab logistics/duty costs
IncotermsFOB, CIF, EXW — international shipping terms

📋 PART 7 — Case Study Question Bank (Practice karo)

Easy

  • Fill Rate 97%, OTIF 82% — kya issue hai?
  • Inventory Turnover 4x se 6x kaise karoge?
  • RTO 8% → 21% — investigate karo
  • Stockout badh raha hai par purchase budget fixed hai — kya karoge?
  • Warehouse me picking slow hai — kaise diagnose karoge?

Medium

  • Ek hub ka SLA breach 40% hai — RCA karo
  • Safety stock badhane se kya-kya impact hoga?
  • Bullwhip effect kaise detect karoge data me?
  • Forecast MAPE 25% hai — kaise improve karoge?
  • COD RTO 21%, Prepaid 8% — COD band kar do? (Trade-off answer do)

Hard

  • Naya warehouse kahan kholo? Kaunse factors dekhoge?
  • 3PL vs in-house fulfillment — kaise decide karoge?
  • Service level 95% → 99% ka business case banao
  • Peak season (BBD) ke liye capacity plan karo
  • Supplier consolidation — kitne suppliers optimal?

✅ PART 8 — Quick Revision (Interview se 1 ghanta pehle)

Formulas jo zubaani aane chahiye:

OTIF              = On-Time ∩ In-Full lines ÷ Total lines
Fill Rate         = Units delivered ÷ Units ordered
DOS               = Current stock ÷ Daily avg sales
ROP               = (Daily sales × Lead time) + Safety stock
Safety Stock      = Z × σ × √Lead Time
EOQ               = √(2DS/H)
Turnover          = COGS ÷ Avg inventory
DOH               = 365 ÷ Turnover
RTO Cost          = RTO count × (fwd + rev freight + handling)
MAPE              = avg(|A−F|/A) × 100
Cost per Delivery = Logistics cost ÷ Deliveries

Answer structure:

Clarify → Decompose (formula) → Hypothesise (MECE) → Validate (data slice) → Recommend (ROI)

5 lines jo har case me bolo:

  • "Pehle main metric ko formula me todta hoon — isse pata chalta hai numerator dekhna hai ya denominator."
  • "Main MECE hypotheses banata hoon — customer, logistics, product, system."
  • "Data ko COD vs Prepaid, tier, category aur TAT me slice karunga."
  • "Recommendations ko Impact × Effort matrix pe prioritise karunga."
  • "Har recommendation ka ROI aur payback period calculate karunga."

Math Python me run karke verify kiya gaya hai (_verify/scm_math_check.py). SQL queries DuckDB pe execute ki gayi hain.

Supply Chain Analytics — Complete!

Is file ke saare numbers Python me actually calculate karke verify kiye gaye hain. Service-level Z-scores, EOQ sensitivity, OTIF math, bullwhip amplification aur MAPE — sab real output hai.

Happy Learning & Keep Exploring! 🚀

👤
Jatin Kumar
Data Analyst & Educator

Python, SQL, Power BI aur Excel mein practical tutorials likhta hoon — taaki data analytics seekhna aasan ho. Portfolio: jatinanalytics.co.in

Portfolio LinkedIn GitHub Kaggle All Articles
Share:

💬 Comments (0)

Spam/links allowed nahi hain — respectful comments welcome!

Loading comments...

Was this article helpful?